diff --git a/api/custom/version.go b/api/custom/version.go index d5ac8e6dd77023b60f60ec84152e216375d83ee3..f9bd53b93a3e43bcf9ef004e8ce4fa1f8e951368 100644 --- a/api/custom/version.go +++ b/api/custom/version.go @@ -10,7 +10,6 @@ import ( func GetVersion(r *http.Request, rctx rcontext.RequestContext, user api.UserInfo) interface{} { unstableFeatures := make(map[string]bool) - unstableFeatures["xyz.amorgan.blurhash"] = rctx.Config.Features.MSC2448Blurhash.Enabled return &api.DoNotCacheResponse{ Payload: map[string]interface{}{ diff --git a/api/r0/upload.go b/api/r0/upload.go index 4153bca484c2c89a5f738e543d427dcaa99866bb..63b0170beb0578b4cdfea0fa07a5add47b8b7dd2 100644 --- a/api/r0/upload.go +++ b/api/r0/upload.go @@ -72,7 +72,7 @@ func UploadMedia(r *http.Request, rctx rcontext.RequestContext, user api.UserInf return api.InternalServerError("Unexpected Error") } - if rctx.Config.Features.MSC2448Blurhash.Enabled { + if rctx.Config.Features.MSC2448Blurhash.Enabled && r.URL.Query().Get("xyz.amorgan.generate_blurhash") == "true" { hash, err := info_controller.GetOrCalculateBlurhash(media, rctx) if err != nil { rctx.Log.Warn("Failed to calculate blurhash: " + err.Error())