createfile

package
v0.0.0-...-4d14c86 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 15, 2026 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrNoData   = errors.New("no file given")
	ErrFileType = errors.New("not an image (PNG, JPEG, GIF, WebP), a PDF, a zip, an audio or a video file")
)

Functions

func Process

func Process(ctx context.Context, db bun.IDB, store silo.Store, input Input) *run

Process stores a file of the account: its row in Postgres, its bytes in Silo.

Types

type Input

type Input struct {
	Name string
	Data []byte
}

Input is a file as sent: its type is read from its bytes, not from what the sender claims.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL
⌂ 换网址