diff --git a/packages/backend/src/server/api/endpoints/notes/hybrid-timeline.ts b/packages/backend/src/server/api/endpoints/notes/hybrid-timeline.ts index 917792a7ff..2b25bec1c5 100644 --- a/packages/backend/src/server/api/endpoints/notes/hybrid-timeline.ts +++ b/packages/backend/src/server/api/endpoints/notes/hybrid-timeline.ts @@ -201,7 +201,7 @@ export default class extends Endpoint { // eslint- } const config = loadConfig(); - const defaultTag: string | null = config.tagging.defaultTag; + const defaultTag: string | null = config.tagging?.defaultTag; if (defaultTag == null) { qb.orWhere('(note.visibility = \'public\') AND (note.userHost IS NULL)'); } else { diff --git a/packages/backend/src/server/api/endpoints/notes/local-timeline.ts b/packages/backend/src/server/api/endpoints/notes/local-timeline.ts index 24f8a303e8..642eb57ed9 100644 --- a/packages/backend/src/server/api/endpoints/notes/local-timeline.ts +++ b/packages/backend/src/server/api/endpoints/notes/local-timeline.ts @@ -152,7 +152,7 @@ export default class extends Endpoint { // eslint- withReplies: boolean, }, me: MiLocalUser | null) { const config = loadConfig(); - const defaultTag: string | null = config.tagging.defaultTag; + const defaultTag: string | null = config.tagging?.defaultTag; const query = this.queryService.makePaginationQuery(this.notesRepository.createQueryBuilder('note'), ps.sinceId, ps.untilId) .andWhere(new Brackets(qb => { diff --git a/packages/backend/src/server/api/stream/channels/hybrid-timeline.ts b/packages/backend/src/server/api/stream/channels/hybrid-timeline.ts index dab99ba400..38196a9c68 100644 --- a/packages/backend/src/server/api/stream/channels/hybrid-timeline.ts +++ b/packages/backend/src/server/api/stream/channels/hybrid-timeline.ts @@ -47,7 +47,7 @@ class HybridTimelineChannel extends Channel { this.withReplies = params.withReplies ?? false; this.withFiles = params.withFiles ?? false; const config = loadConfig(); - this.defaultTag = config.tagging.defaultTag; + this.defaultTag = config.tagging?.defaultTag; // Subscribe events this.subscriber.on('notesStream', this.onNote);