federation_service: remove trailing slash from repository inbox

The API endpoint specifies that the repository inbox is
{repository-id}/inbox, not {repository-id}/inbox/. The HTTP signature
validation relies on that to properly validate the signature incoming request.
This commit is contained in:
famfo 2025-02-23 02:52:57 +01:00
parent c9853e9e3a
commit 1f73db1ae8
No known key found for this signature in database

View file

@ -285,7 +285,7 @@ func SendLikeActivities(ctx context.Context, doer user.User, repoID int64) error
return err
}
_, err = apclient.Post(json, fmt.Sprintf("%v/inbox/", activity.Object))
_, err = apclient.Post(json, fmt.Sprintf("%v/inbox", activity.Object))
if err != nil {
log.Error("error %v while sending activity: %q", err, activity)
}