diff options
Diffstat (limited to '')
| -rw-r--r-- | packages/backend/src/core/UtilityService.ts | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/packages/backend/src/core/UtilityService.ts b/packages/backend/src/core/UtilityService.ts index a90774cf59..c15c587cd7 100644 --- a/packages/backend/src/core/UtilityService.ts +++ b/packages/backend/src/core/UtilityService.ts @@ -30,18 +30,20 @@ export class UtilityService { @bindThis public getFullApAccount(username: string, host: string | null): string { - return host ? `${username}@${this.toPuny(host)}` : `${username}@${this.toPuny(this.config.host)}`; + return host ? `${username}@${this.toPuny(host)}` : `${username}@${this.toPuny(this.config.localHost)}`; } @bindThis public isSelfHost(host: string | null): boolean { if (host == null) return true; - return this.toPuny(this.config.host) === this.toPuny(host); + return (this.toPuny(this.config.localHost) === this.toPuny(host)) || + (this.toPuny(this.config.webHost) === this.toPuny(host)) } @bindThis public isUriLocal(uri: string): boolean { - return this.punyHost(uri) === this.toPuny(this.config.host); + return (this.punyHost(uri) === this.toPuny(this.config.localHost)) || + (this.punyHost(uri) === this.toPuny(this.config.webHost)) } // メールアドレスのバリデーションを行う |