refactor(federation): 🚚 Change Like path from /objects/{id} to /likes/{id}

This commit is contained in:
Jesse Wierzbinski 2025-03-28 22:06:42 +01:00
parent 3d3e64edab
commit d75254fc71
No known key found for this signature in database
18 changed files with 102 additions and 112 deletions

View file

@ -146,7 +146,7 @@ export class Like extends BaseInterface<typeof Likes, LikeType> {
}
public getUri(): URL {
return new URL(`/objects/${this.data.id}`, config.http.base_url);
return new URL(`/likes/${this.data.id}`, config.http.base_url);
}
public toVersia(): LikeExtension {

View file

@ -100,6 +100,14 @@ export class ApiError extends Error {
);
}
public static likeNotFound(): ApiError {
return new ApiError(
404,
"Like not found",
"The requested like could not be found.",
);
}
public static pushSubscriptionNotFound(): ApiError {
return new ApiError(
404,