even more refactor

This commit is contained in:
2021-10-14 19:00:11 +02:00
parent d2b0364445
commit 439e5473b6
10 changed files with 372 additions and 414 deletions

View File

@@ -20,6 +20,7 @@ import (
log "github.com/sirupsen/logrus"
helper "git.kapelle.org/niklas/s3browser/internal/helper"
"git.kapelle.org/niklas/s3browser/internal/loader"
types "git.kapelle.org/niklas/s3browser/internal/types"
)
@@ -195,7 +196,7 @@ func httpPostFile(ctx context.Context, rw http.ResponseWriter, r *http.Request)
}
// Invalidate cache
helper.InvalidateCache(ctx, *id)
ctx.Value("loader").(*loader.Loader).InvalidateCacheForFile(ctx, *id)
rw.WriteHeader(http.StatusCreated)
}