diff --git a/mediaapi/routing/routing.go b/mediaapi/routing/routing.go index bc0de0f45..f4a8b1575 100644 --- a/mediaapi/routing/routing.go +++ b/mediaapi/routing/routing.go @@ -53,12 +53,16 @@ func Setup( activeThumbnailGeneration := &types.ActiveThumbnailGeneration{ PathToResult: map[string]*types.ThumbnailGenerationResult{}, } - r0mux.Handle("/upload", httputil.MakeAuthAPI( + + uploadHandler := httputil.MakeAuthAPI( "upload", userAPI, func(req *http.Request, _ *userapi.Device) util.JSONResponse { return Upload(req, cfg, db, activeThumbnailGeneration) }, - )).Methods(http.MethodPost, http.MethodOptions) + ) + + r0mux.Handle("/upload", uploadHandler).Methods(http.MethodPost, http.MethodOptions) + v1mux.Handle("/upload", uploadHandler).Methods(http.MethodPost, http.MethodOptions) activeRemoteRequests := &types.ActiveRemoteRequests{ MXCToResult: map[string]*types.RemoteRequestResult{},