Added publishing of uploads to built site

This commit is contained in:
Leon Mika 2026-03-03 22:36:24 +11:00
parent 48f39133d7
commit d0cebe6564
13 changed files with 145 additions and 20 deletions

View file

@ -37,6 +37,10 @@ func (p *Provider) OpenUpload(site models.Site, up models.Upload) (io.ReadCloser
return os.Open(fullPath)
}
func (p *Provider) UploadDir(site models.Site) string {
return filepath.Join(p.baseDir, site.GUID)
}
func (p *Provider) uploadFileName(site models.Site, up models.Upload) string {
return filepath.Join(p.baseDir, site.GUID, up.Slug)
}