Merge branch 'develop' of git.joinfirefish.org:firefish/firefish into develop
This commit is contained in:
commit
05b7fd0fc5
@ -23,7 +23,7 @@ import {
|
|||||||
} from "@/misc/populate-emojis.js";
|
} from "@/misc/populate-emojis.js";
|
||||||
import { db } from "@/db/postgre.js";
|
import { db } from "@/db/postgre.js";
|
||||||
import { IdentifiableError } from "@/misc/identifiable-error.js";
|
import { IdentifiableError } from "@/misc/identifiable-error.js";
|
||||||
import { detect as detectLanguage_ } from "tinyld";
|
import { detect as detectLanguage } from "tinyld";
|
||||||
|
|
||||||
export async function populatePoll(note: Note, meId: User["id"] | null) {
|
export async function populatePoll(note: Note, meId: User["id"] | null) {
|
||||||
const poll = await Polls.findOneByOrFail({ noteId: note.id });
|
const poll = await Polls.findOneByOrFail({ noteId: note.id });
|
||||||
@ -200,7 +200,7 @@ export const NoteRepository = db.getRepository(Note).extend({
|
|||||||
);
|
);
|
||||||
|
|
||||||
const lang =
|
const lang =
|
||||||
detectLanguage_(`${note.cw ?? ""}\n${note.text ?? ""}`) ?? "unknown";
|
detectLanguage(`${note.cw ?? ""}\n${note.text ?? ""}`) ?? "unknown";
|
||||||
const reactionEmoji = await populateEmojis(reactionEmojiNames, host);
|
const reactionEmoji = await populateEmojis(reactionEmojiNames, host);
|
||||||
const packed: Packed<"Note"> = await awaitAll({
|
const packed: Packed<"Note"> = await awaitAll({
|
||||||
id: note.id,
|
id: note.id,
|
||||||
|
Loading…
Reference in New Issue
Block a user