fix: emojis not being populated for local users
This commit is contained in:
parent
d0af17c674
commit
7481ece433
3 changed files with 15 additions and 3 deletions
|
|
@ -22,6 +22,7 @@ import type { CustomEmojiService } from '../CustomEmojiService.js';
|
|||
import type { ReactionService } from '../ReactionService.js';
|
||||
import type { UserEntityService } from './UserEntityService.js';
|
||||
import type { DriveFileEntityService } from './DriveFileEntityService.js';
|
||||
import type { Config } from '@/config.js';
|
||||
|
||||
@Injectable()
|
||||
export class NoteEntityService implements OnModuleInit {
|
||||
|
|
@ -36,6 +37,9 @@ export class NoteEntityService implements OnModuleInit {
|
|||
@Inject(DI.usersRepository)
|
||||
private usersRepository: UsersRepository,
|
||||
|
||||
@Inject(DI.config)
|
||||
private config: Config,
|
||||
|
||||
@Inject(DI.notesRepository)
|
||||
private notesRepository: NotesRepository,
|
||||
|
||||
|
|
@ -286,7 +290,7 @@ export class NoteEntityService implements OnModuleInit {
|
|||
|
||||
const meId = me ? me.id : null;
|
||||
const note = typeof src === 'object' ? src : await this.notesRepository.findOneOrFail({ where: { id: src }, relations: ['user'] });
|
||||
const host = note.userHost;
|
||||
const host = note.userHost === null ? this.config.host : note.userHost;
|
||||
|
||||
let text = note.text;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue