mirror of
https://github.com/aljazceru/ditto.git
synced 2025-12-26 17:54:28 +01:00
Rename blocks to mutes in the API
This commit is contained in:
@@ -272,8 +272,8 @@ const followingController: AppController = async (c) => {
|
||||
return renderAccounts(c, pubkeys);
|
||||
};
|
||||
|
||||
/** https://docs.joinmastodon.org/methods/accounts/#block */
|
||||
const blockController: AppController = async (c) => {
|
||||
/** https://docs.joinmastodon.org/methods/accounts/#mute */
|
||||
const muteController: AppController = async (c) => {
|
||||
const sourcePubkey = c.get('pubkey')!;
|
||||
const targetPubkey = c.req.param('pubkey');
|
||||
|
||||
@@ -287,8 +287,8 @@ const blockController: AppController = async (c) => {
|
||||
return c.json(relationship);
|
||||
};
|
||||
|
||||
/** https://docs.joinmastodon.org/methods/accounts/#unblock */
|
||||
const unblockController: AppController = async (c) => {
|
||||
/** https://docs.joinmastodon.org/methods/accounts/#unmute */
|
||||
const unmuteController: AppController = async (c) => {
|
||||
const sourcePubkey = c.get('pubkey')!;
|
||||
const targetPubkey = c.req.param('pubkey');
|
||||
|
||||
@@ -328,15 +328,15 @@ export {
|
||||
accountLookupController,
|
||||
accountSearchController,
|
||||
accountStatusesController,
|
||||
blockController,
|
||||
createAccountController,
|
||||
favouritesController,
|
||||
followController,
|
||||
followersController,
|
||||
followingController,
|
||||
muteController,
|
||||
relationshipsController,
|
||||
unblockController,
|
||||
unfollowController,
|
||||
unmuteController,
|
||||
updateCredentialsController,
|
||||
verifyCredentialsController,
|
||||
};
|
||||
|
||||
@@ -3,8 +3,8 @@ import { Storages } from '@/storages.ts';
|
||||
import { getTagSet } from '@/tags.ts';
|
||||
import { renderAccounts } from '@/views.ts';
|
||||
|
||||
/** https://docs.joinmastodon.org/methods/blocks/#get */
|
||||
const blocksController: AppController = async (c) => {
|
||||
/** https://docs.joinmastodon.org/methods/mutes/#get */
|
||||
const mutesController: AppController = async (c) => {
|
||||
const pubkey = c.get('pubkey')!;
|
||||
const { signal } = c.req.raw;
|
||||
|
||||
@@ -21,4 +21,4 @@ const blocksController: AppController = async (c) => {
|
||||
}
|
||||
};
|
||||
|
||||
export { blocksController };
|
||||
export { mutesController };
|
||||
Reference in New Issue
Block a user