From 006c8b604b88fdddf1a2319e44aa37dd8777efd9 Mon Sep 17 00:00:00 2001 From: tobi <31960611+tsmethurst@users.noreply.github.com> Date: Sun, 4 Sep 2022 14:41:42 +0200 Subject: [feature] Set default header and avatar for API accounts to GtS ones (#799) * validate web-asset-base-dir * move default icons into converter * always ensure avatar + header on api accounts * update tests * add default header * don't return error from web module creation anymore * tidy a bit * use pngs for default avatars rather than svgs --- internal/web/assetscache.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'internal/web/assetscache.go') diff --git a/internal/web/assetscache.go b/internal/web/assetscache.go index 57a0ade0b..fccc95993 100644 --- a/internal/web/assetscache.go +++ b/internal/web/assetscache.go @@ -114,7 +114,7 @@ func (m *Module) cacheControlMiddleware(fs http.FileSystem) gin.HandlerFunc { if !strings.HasPrefix(upath, "/") { upath = "/" + upath } - assetFilePath := strings.TrimPrefix(path.Clean(upath), assetsPath) + assetFilePath := strings.TrimPrefix(path.Clean(upath), assetsPathPrefix) // either fetch etag from ttlcache or generate it eTag, err := m.getAssetETag(assetFilePath, fs) -- cgit v1.2.3