feat: eslint 적용 및 관련 코드 일괄 수정
This commit is contained in:
@@ -50,10 +50,7 @@ const toMessageView = (row: MessageRow): MessageView => {
|
||||
};
|
||||
};
|
||||
|
||||
export const insertMessage = async (
|
||||
db: DatabaseClient,
|
||||
draft: MessageRecordDraft
|
||||
): Promise<number> => {
|
||||
export const insertMessage = async (db: DatabaseClient, draft: MessageRecordDraft): Promise<number> => {
|
||||
const rows = await db.$queryRaw<Array<{ id: number }>>`
|
||||
INSERT INTO message (mailbox, type, src, dest, time, valid_until, message)
|
||||
VALUES (
|
||||
|
||||
@@ -21,10 +21,7 @@ export const resolveNationInfo = async (
|
||||
return { name: nation.name, color: nation.color };
|
||||
};
|
||||
|
||||
export const buildTargetFromGeneral = async (
|
||||
db: DatabaseClient,
|
||||
general: GeneralRow
|
||||
): Promise<MessageTarget> => {
|
||||
export const buildTargetFromGeneral = async (db: DatabaseClient, general: GeneralRow): Promise<MessageTarget> => {
|
||||
const nation = await resolveNationInfo(db, general.nationId);
|
||||
return {
|
||||
generalId: general.id,
|
||||
@@ -36,11 +33,7 @@ export const buildTargetFromGeneral = async (
|
||||
};
|
||||
};
|
||||
|
||||
export const buildNationTarget = (
|
||||
nationId: number,
|
||||
nationName: string,
|
||||
color: string
|
||||
): MessageTarget => ({
|
||||
export const buildNationTarget = (nationId: number, nationName: string, color: string): MessageTarget => ({
|
||||
generalId: 0,
|
||||
generalName: '',
|
||||
nationId,
|
||||
|
||||
Reference in New Issue
Block a user