From e2689a1d8dc866e7ce5f868db3c0d92ffc9c6a1c Mon Sep 17 00:00:00 2001 From: hijiki Date: Fri, 8 Nov 2024 04:28:00 +0900 Subject: [PATCH] =?UTF-8?q?=E3=81=BB=E3=81=A8=E3=82=93=E3=81=A9=E3=81=AEap?= =?UTF-8?q?i=E3=82=A8=E3=83=B3=E3=83=89=E3=83=9D=E3=82=A4=E3=83=B3?= =?UTF-8?q?=E3=83=88=E3=82=92=E8=AA=8D=E8=A8=BC=E3=81=82=E3=82=8A=E3=81=AB?= =?UTF-8?q?=E3=81=97=E3=81=9F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/backend/src/server/api/endpoints/notes.ts | 2 ++ packages/backend/src/server/api/endpoints/notes/show.ts | 2 +- packages/backend/src/server/api/endpoints/roles/show.ts | 2 +- packages/backend/src/server/api/endpoints/roles/users.ts | 2 +- .../backend/src/server/api/endpoints/username/available.ts | 2 +- packages/backend/src/server/api/endpoints/users.ts | 2 +- .../backend/src/server/api/endpoints/users/achievements.ts | 3 ++- packages/backend/src/server/api/endpoints/users/clips.ts | 1 + packages/backend/src/server/api/endpoints/users/flashs.ts | 1 + packages/backend/src/server/api/endpoints/users/followers.ts | 2 +- packages/backend/src/server/api/endpoints/users/following.ts | 2 +- .../backend/src/server/api/endpoints/users/gallery/posts.ts | 1 + .../api/endpoints/users/get-frequently-replied-users.ts | 2 +- .../src/server/api/endpoints/users/lists/get-memberships.ts | 2 +- packages/backend/src/server/api/endpoints/users/lists/list.ts | 2 +- packages/backend/src/server/api/endpoints/users/lists/show.ts | 2 +- packages/backend/src/server/api/endpoints/users/notes.ts | 2 +- packages/backend/src/server/api/endpoints/users/pages.ts | 1 + packages/backend/src/server/api/endpoints/users/reactions.ts | 2 +- .../server/api/endpoints/users/search-by-username-and-host.ts | 2 +- packages/backend/src/server/api/endpoints/users/search.ts | 2 +- packages/backend/src/server/api/endpoints/users/show.ts | 2 +- packages/frontend/src/components/MkVisitorDashboard.vue | 4 ++-- packages/frontend/src/pages/welcome.entrance.a.vue | 2 +- 24 files changed, 27 insertions(+), 20 deletions(-) diff --git a/packages/backend/src/server/api/endpoints/notes.ts b/packages/backend/src/server/api/endpoints/notes.ts index 9938322a2a..286a5fe45e 100755 --- a/packages/backend/src/server/api/endpoints/notes.ts +++ b/packages/backend/src/server/api/endpoints/notes.ts @@ -13,6 +13,8 @@ import { DI } from '@/di-symbols.js'; export const meta = { tags: ['notes'], + requireCredential: true, + res: { type: 'array', optional: false, nullable: false, diff --git a/packages/backend/src/server/api/endpoints/notes/show.ts b/packages/backend/src/server/api/endpoints/notes/show.ts index 4afc525e57..3eca63c391 100755 --- a/packages/backend/src/server/api/endpoints/notes/show.ts +++ b/packages/backend/src/server/api/endpoints/notes/show.ts @@ -14,7 +14,7 @@ import { ApiError } from '../../error.js'; export const meta = { tags: ['notes'], - requireCredential: false, + requireCredential: true, res: { type: 'object', diff --git a/packages/backend/src/server/api/endpoints/roles/show.ts b/packages/backend/src/server/api/endpoints/roles/show.ts index 38477c5e8e..f7ba05e862 100755 --- a/packages/backend/src/server/api/endpoints/roles/show.ts +++ b/packages/backend/src/server/api/endpoints/roles/show.ts @@ -13,7 +13,7 @@ import { ApiError } from '../../error.js'; export const meta = { tags: ['role', 'users'], - requireCredential: false, + requireCredential: true, errors: { noSuchRole: { diff --git a/packages/backend/src/server/api/endpoints/roles/users.ts b/packages/backend/src/server/api/endpoints/roles/users.ts index 48d350af59..613536fccb 100755 --- a/packages/backend/src/server/api/endpoints/roles/users.ts +++ b/packages/backend/src/server/api/endpoints/roles/users.ts @@ -15,7 +15,7 @@ import { ApiError } from '../../error.js'; export const meta = { tags: ['role', 'users'], - requireCredential: false, + requireCredential: true, errors: { noSuchRole: { diff --git a/packages/backend/src/server/api/endpoints/username/available.ts b/packages/backend/src/server/api/endpoints/username/available.ts index 4944be9b05..3a82a383a4 100755 --- a/packages/backend/src/server/api/endpoints/username/available.ts +++ b/packages/backend/src/server/api/endpoints/username/available.ts @@ -13,7 +13,7 @@ import { DI } from '@/di-symbols.js'; export const meta = { tags: ['users'], - requireCredential: false, + requireCredential: true, res: { type: 'object', diff --git a/packages/backend/src/server/api/endpoints/users.ts b/packages/backend/src/server/api/endpoints/users.ts index e845853017..0484308678 100755 --- a/packages/backend/src/server/api/endpoints/users.ts +++ b/packages/backend/src/server/api/endpoints/users.ts @@ -13,7 +13,7 @@ import { DI } from '@/di-symbols.js'; export const meta = { tags: ['users'], - requireCredential: false, + requireCredential: true, res: { type: 'array', diff --git a/packages/backend/src/server/api/endpoints/users/achievements.ts b/packages/backend/src/server/api/endpoints/users/achievements.ts index f7139b3684..da42cf75f1 100755 --- a/packages/backend/src/server/api/endpoints/users/achievements.ts +++ b/packages/backend/src/server/api/endpoints/users/achievements.ts @@ -9,7 +9,8 @@ import type { UserProfilesRepository } from '@/models/_.js'; import { DI } from '@/di-symbols.js'; export const meta = { - requireCredential: false, + + requireCredential: true, res: { type: 'array', diff --git a/packages/backend/src/server/api/endpoints/users/clips.ts b/packages/backend/src/server/api/endpoints/users/clips.ts index 7f7d2ea8cc..d80cd61348 100755 --- a/packages/backend/src/server/api/endpoints/users/clips.ts +++ b/packages/backend/src/server/api/endpoints/users/clips.ts @@ -13,6 +13,7 @@ import { DI } from '@/di-symbols.js'; export const meta = { tags: ['users', 'clips'], + requireCredential: true, description: 'Show all clips this user owns.', res: { diff --git a/packages/backend/src/server/api/endpoints/users/flashs.ts b/packages/backend/src/server/api/endpoints/users/flashs.ts index e5ea450215..95032fac1e 100755 --- a/packages/backend/src/server/api/endpoints/users/flashs.ts +++ b/packages/backend/src/server/api/endpoints/users/flashs.ts @@ -13,6 +13,7 @@ import { DI } from '@/di-symbols.js'; export const meta = { tags: ['users', 'flashs'], + requireCredential: true, description: 'Show all flashs this user created.', res: { diff --git a/packages/backend/src/server/api/endpoints/users/followers.ts b/packages/backend/src/server/api/endpoints/users/followers.ts index 7634abf236..f56542e001 100755 --- a/packages/backend/src/server/api/endpoints/users/followers.ts +++ b/packages/backend/src/server/api/endpoints/users/followers.ts @@ -16,7 +16,7 @@ import { ApiError } from '../../error.js'; export const meta = { tags: ['users'], - requireCredential: false, + requireCredential: true, description: 'Show everyone that follows this user.', diff --git a/packages/backend/src/server/api/endpoints/users/following.ts b/packages/backend/src/server/api/endpoints/users/following.ts index 2ab31a435c..32ce191c6a 100755 --- a/packages/backend/src/server/api/endpoints/users/following.ts +++ b/packages/backend/src/server/api/endpoints/users/following.ts @@ -17,7 +17,7 @@ import { ApiError } from '../../error.js'; export const meta = { tags: ['users'], - requireCredential: false, + requireCredential: true, description: 'Show everyone that this user is following.', diff --git a/packages/backend/src/server/api/endpoints/users/gallery/posts.ts b/packages/backend/src/server/api/endpoints/users/gallery/posts.ts index 553886374c..b344cb07d0 100755 --- a/packages/backend/src/server/api/endpoints/users/gallery/posts.ts +++ b/packages/backend/src/server/api/endpoints/users/gallery/posts.ts @@ -13,6 +13,7 @@ import { DI } from '@/di-symbols.js'; export const meta = { tags: ['users', 'gallery'], + requireCredential: true, description: 'Show all gallery posts by the given user.', res: { diff --git a/packages/backend/src/server/api/endpoints/users/get-frequently-replied-users.ts b/packages/backend/src/server/api/endpoints/users/get-frequently-replied-users.ts index 9248a2fa68..27b56c0968 100755 --- a/packages/backend/src/server/api/endpoints/users/get-frequently-replied-users.ts +++ b/packages/backend/src/server/api/endpoints/users/get-frequently-replied-users.ts @@ -16,7 +16,7 @@ import { ApiError } from '../../error.js'; export const meta = { tags: ['users'], - requireCredential: false, + requireCredential: true, description: 'Get a list of other users that the specified user frequently replies to.', diff --git a/packages/backend/src/server/api/endpoints/users/lists/get-memberships.ts b/packages/backend/src/server/api/endpoints/users/lists/get-memberships.ts index 6d6e8d34ea..a49cea4a76 100755 --- a/packages/backend/src/server/api/endpoints/users/lists/get-memberships.ts +++ b/packages/backend/src/server/api/endpoints/users/lists/get-memberships.ts @@ -14,7 +14,7 @@ import { ApiError } from '../../../error.js'; export const meta = { tags: ['lists', 'account'], - requireCredential: false, + requireCredential: true, kind: 'read:account', diff --git a/packages/backend/src/server/api/endpoints/users/lists/list.ts b/packages/backend/src/server/api/endpoints/users/lists/list.ts index 4241ef1cd0..94f63f5475 100755 --- a/packages/backend/src/server/api/endpoints/users/lists/list.ts +++ b/packages/backend/src/server/api/endpoints/users/lists/list.ts @@ -13,7 +13,7 @@ import { DI } from '@/di-symbols.js'; export const meta = { tags: ['lists', 'account'], - requireCredential: false, + requireCredential: true, kind: 'read:account', diff --git a/packages/backend/src/server/api/endpoints/users/lists/show.ts b/packages/backend/src/server/api/endpoints/users/lists/show.ts index 8756801fe4..5144d7a714 100755 --- a/packages/backend/src/server/api/endpoints/users/lists/show.ts +++ b/packages/backend/src/server/api/endpoints/users/lists/show.ts @@ -13,7 +13,7 @@ import { ApiError } from '../../../error.js'; export const meta = { tags: ['lists', 'account'], - requireCredential: false, + requireCredential: true, kind: 'read:account', diff --git a/packages/backend/src/server/api/endpoints/users/notes.ts b/packages/backend/src/server/api/endpoints/users/notes.ts index 40fa5d92bf..5038c1ee0d 100755 --- a/packages/backend/src/server/api/endpoints/users/notes.ts +++ b/packages/backend/src/server/api/endpoints/users/notes.ts @@ -21,7 +21,7 @@ import { isQuote, isRenote } from '@/misc/is-renote.js'; export const meta = { tags: ['users', 'notes'], - requireCredential: false, + requireCredential: true, res: { type: 'array', diff --git a/packages/backend/src/server/api/endpoints/users/pages.ts b/packages/backend/src/server/api/endpoints/users/pages.ts index bb7de0e0b5..31d2fc718d 100755 --- a/packages/backend/src/server/api/endpoints/users/pages.ts +++ b/packages/backend/src/server/api/endpoints/users/pages.ts @@ -13,6 +13,7 @@ import { DI } from '@/di-symbols.js'; export const meta = { tags: ['users', 'pages'], + requireCredential: true, description: 'Show all pages this user created.', res: { diff --git a/packages/backend/src/server/api/endpoints/users/reactions.ts b/packages/backend/src/server/api/endpoints/users/reactions.ts index 7805ae3288..5b33f1f67b 100755 --- a/packages/backend/src/server/api/endpoints/users/reactions.ts +++ b/packages/backend/src/server/api/endpoints/users/reactions.ts @@ -18,7 +18,7 @@ import { ApiError } from '../../error.js'; export const meta = { tags: ['users', 'reactions'], - requireCredential: false, + requireCredential: true, description: 'Show all reactions this user made.', diff --git a/packages/backend/src/server/api/endpoints/users/search-by-username-and-host.ts b/packages/backend/src/server/api/endpoints/users/search-by-username-and-host.ts index 8ff952dcb5..b46bd5c72e 100755 --- a/packages/backend/src/server/api/endpoints/users/search-by-username-and-host.ts +++ b/packages/backend/src/server/api/endpoints/users/search-by-username-and-host.ts @@ -10,7 +10,7 @@ import { UserSearchService } from '@/core/UserSearchService.js'; export const meta = { tags: ['users'], - requireCredential: false, + requireCredential: true, description: 'Search for a user by username and/or host.', diff --git a/packages/backend/src/server/api/endpoints/users/search.ts b/packages/backend/src/server/api/endpoints/users/search.ts index 0b0136066d..2191df9481 100755 --- a/packages/backend/src/server/api/endpoints/users/search.ts +++ b/packages/backend/src/server/api/endpoints/users/search.ts @@ -15,7 +15,7 @@ import { sqlLikeEscape } from '@/misc/sql-like-escape.js'; export const meta = { tags: ['users'], - requireCredential: false, + requireCredential: true, description: 'Search for users.', diff --git a/packages/backend/src/server/api/endpoints/users/show.ts b/packages/backend/src/server/api/endpoints/users/show.ts index 062326e28d..2c6f8c9883 100755 --- a/packages/backend/src/server/api/endpoints/users/show.ts +++ b/packages/backend/src/server/api/endpoints/users/show.ts @@ -20,7 +20,7 @@ import type { FindOptionsWhere } from 'typeorm'; export const meta = { tags: ['users'], - requireCredential: false, + requireCredential: true, description: 'Show the properties of a user.', diff --git a/packages/frontend/src/components/MkVisitorDashboard.vue b/packages/frontend/src/components/MkVisitorDashboard.vue index e205e390b1..2f76fd4881 100755 --- a/packages/frontend/src/components/MkVisitorDashboard.vue +++ b/packages/frontend/src/components/MkVisitorDashboard.vue @@ -42,10 +42,10 @@ SPDX-License-Identifier: AGPL-3.0-only -->
-
{{ i18n.ts.letsLookAtTimeline }}
+