+3
cmd/bluepages/handlers.go
+3
cmd/bluepages/handlers.go
···
74
74
func (srv *Server) resolveIdentityFromHandle(c echo.Context, handle syntax.Handle) error {
75
75
ctx := c.Request().Context()
76
76
77
+
handle = handle.Normalize()
78
+
77
79
did, err := srv.dir.ResolveHandle(ctx, handle)
78
80
if err != nil && errors.Is(err, identity.ErrHandleNotFound) {
79
81
return c.JSON(404, GenericError{
···
110
112
}
111
113
112
114
ident := identity.ParseIdentity(&doc)
115
+
// NOTE: 'handle' was resolved above, and 'DeclaredHandle()' returns a normalized handle
113
116
declHandle, err := ident.DeclaredHandle()
114
117
if err != nil || declHandle != handle {
115
118
return c.JSON(400, GenericError{