Browse Source

Redirect /embed/chat to /embed/chat/readonly. Closes #2716

pull/2721/head
Gabe Kangas 3 years ago
parent
commit
3cccfbfc06
No known key found for this signature in database
GPG Key ID: 4345B2060657F330
  1. 5
      router/router.go

5
router/router.go

@ -383,6 +383,11 @@ func Start() error { @@ -383,6 +383,11 @@ func Start() error {
http.HandleFunc("/api/auth/fediverse", middleware.RequireUserAccessToken(fediverseauth.RegisterFediverseOTPRequest))
http.HandleFunc("/api/auth/fediverse/verify", fediverseauth.VerifyFediverseOTPRequest)
// Redirect /embed/chat
http.HandleFunc("/embed/chat", func(w http.ResponseWriter, r *http.Request) {
http.Redirect(w, r, "/embed/chat/readonly", http.StatusTemporaryRedirect)
})
// ActivityPub has its own router
activitypub.Start(data.GetDatastore())

Loading…
Cancel
Save