mirror of
https://github.com/versia-pub/versia-go.git
synced 2026-03-13 12:39:15 +01:00
refactor(server): rename stuff from Lysand to Versia
Big diff energy
This commit is contained in:
parent
03e01548dc
commit
cb135706e2
29 changed files with 103 additions and 96 deletions
|
|
@ -27,9 +27,9 @@ func New(instanceMetadataService service.InstanceMetadataService, log logr.Logge
|
|||
}
|
||||
|
||||
func (i *Handler) Register(r fiber.Router) {
|
||||
r.Get("/.well-known/versia", i.GetLysandInstanceMetadata)
|
||||
r.Get("/.well-known/versia/admins", i.GetLysandInstanceMetadata)
|
||||
r.Get("/.well-known/versia/moderators", i.GetLysandInstanceMetadata)
|
||||
r.Get("/.well-known/versia", i.GetVersiaInstanceMetadata)
|
||||
r.Get("/.well-known/versia/admins", i.GetVersiaInstanceMetadata)
|
||||
r.Get("/.well-known/versia/moderators", i.GetVersiaInstanceMetadata)
|
||||
|
||||
// Webfinger host meta spec
|
||||
r.Get("/.well-known/host-meta", i.GetHostMeta)
|
||||
|
|
|
|||
|
|
@ -4,11 +4,12 @@ import (
|
|||
"github.com/gofiber/fiber/v2"
|
||||
)
|
||||
|
||||
func (i *Handler) GetLysandInstanceMetadata(c *fiber.Ctx) error {
|
||||
func (i *Handler) GetVersiaInstanceMetadata(c *fiber.Ctx) error {
|
||||
m, err := i.instanceMetadataService.Ours(c.UserContext())
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
return c.JSON(m.ToLysand())
|
||||
// TODO: Sign with the instance private key
|
||||
return c.JSON(m.ToVersia())
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue