被りにくい名前にする
This commit is contained in:
parent
8af13a6502
commit
94663e1bf0
|
@ -3,6 +3,6 @@
|
||||||
* SPDX-License-Identifier: AGPL-3.0-only
|
* SPDX-License-Identifier: AGPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
export function keys<T extends { [x: string]: unknown }>(obj: T): (keyof T)[] {
|
export function getObjKeys<T extends { [x: string]: unknown }>(obj: T): (keyof T)[] {
|
||||||
return Object.keys(obj);
|
return Object.keys(obj);
|
||||||
}
|
}
|
||||||
|
|
|
@ -11,7 +11,7 @@ import { JSDOM } from 'jsdom';
|
||||||
import { extractCustomEmojisFromMfm } from '@/misc/extract-custom-emojis-from-mfm.js';
|
import { extractCustomEmojisFromMfm } from '@/misc/extract-custom-emojis-from-mfm.js';
|
||||||
import { extractHashtags } from '@/misc/extract-hashtags.js';
|
import { extractHashtags } from '@/misc/extract-hashtags.js';
|
||||||
import * as Acct from '@/misc/acct.js';
|
import * as Acct from '@/misc/acct.js';
|
||||||
import { keys } from '@/misc/prelude/object.js';
|
import { getObjKeys } from '@/misc/prelude/object.js';
|
||||||
import type { UsersRepository, DriveFilesRepository, UserProfilesRepository, PagesRepository } from '@/models/_.js';
|
import type { UsersRepository, DriveFilesRepository, UserProfilesRepository, PagesRepository } from '@/models/_.js';
|
||||||
import type { MiLocalUser, MiUser } from '@/models/User.js';
|
import type { MiLocalUser, MiUser } from '@/models/User.js';
|
||||||
import { birthdaySchema, descriptionSchema, locationSchema, nameSchema } from '@/models/User.js';
|
import { birthdaySchema, descriptionSchema, locationSchema, nameSchema } from '@/models/User.js';
|
||||||
|
@ -506,8 +506,8 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
||||||
|
|
||||||
// 連合する必要があるプロパティが変更されている場合はフォロワーにUpdateを配信
|
// 連合する必要があるプロパティが変更されている場合はフォロワーにUpdateを配信
|
||||||
if (
|
if (
|
||||||
miLocalUserKeysUsedForApPersonRender.some(k => keys(updates).includes(k)) ||
|
miLocalUserKeysUsedForApPersonRender.some(k => getObjKeys(updates).includes(k)) ||
|
||||||
miUserProfileKeysUsedForApPersonRender.some(k => keys(profileUpdates).includes(k))
|
miUserProfileKeysUsedForApPersonRender.some(k => getObjKeys(profileUpdates).includes(k))
|
||||||
) {
|
) {
|
||||||
this.accountUpdateService.publishToFollowers(user.id);
|
this.accountUpdateService.publishToFollowers(user.id);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue