diff --git a/backend/go-app/main.go b/backend/go-app/main.go index daa4e453..2b944bfd 100755 --- a/backend/go-app/main.go +++ b/backend/go-app/main.go @@ -3066,8 +3066,8 @@ func buildSwaggerApp(resp http.ResponseWriter, body []byte, user shuffle.User, s // FIXME: Check whether it's in use. if user.Id != app.Owner && user.Role != "admin" { log.Printf("[WARNING] Wrong user (%s) for app %s when verifying swagger", user.Username, app.Name) - resp.WriteHeader(400) - resp.Write([]byte(`{"success": false}`)) + resp.WriteHeader(403) + resp.Write([]byte(`{"success": false, "reason": "You don't have permissions to edit this app. Contact support@shuffler.io if this persists."}`)) return } @@ -5781,6 +5781,8 @@ func makeWorkflowPublic(resp http.ResponseWriter, request *http.Request) { resp.Write([]byte(fmt.Sprintf(`{"success": true}`))) } + + func handleAppZipUpload(resp http.ResponseWriter, request *http.Request) { cors := shuffle.HandleCors(resp, request) if cors {