mirror of
https://iceshrimp.dev/iceshrimp/iceshrimp
synced 2024-11-27 14:28:08 +09:00
[mastodon-client] Fix verify_credentials occasionally showing outdated data
This commit is contained in:
parent
01b5af2686
commit
5d17996d5f
@ -192,7 +192,8 @@ export class UserHelpers {
|
||||
}
|
||||
|
||||
public static async verifyCredentials(user: ILocalUser): Promise<MastodonEntity.Account> {
|
||||
const acct = UserConverter.encode(user);
|
||||
// re-fetch local user because auth user possibly contains outdated info
|
||||
const acct = getUser(user.id).then(u => UserConverter.encode(u));
|
||||
const profile = UserProfiles.findOneByOrFail({userId: user.id});
|
||||
const privacy = this.getDefaultNoteVisibility(user);
|
||||
const fields = profile.then(profile => profile.fields.map(field => {
|
||||
|
Loading…
Reference in New Issue
Block a user