style(mail-ingest): wrap the repository lines the way prettier does

The new repositories and their tests held a few lines past the 120-column print width.
This commit is contained in:
Maurice
2026-11-13 15:39:14 +01:00
parent aa84d71302
commit 5f600cf263
5 changed files with 45 additions and 10 deletions
@@ -151,7 +151,11 @@ export class MailIngestCandidatesRepository extends TrekRepository<MailIngestCan
}
async findById(id: number): Promise<MailIngestCandidateRow | null> {
const row = await this.db().selectFrom('mail_ingest_candidates').selectAll().where('id', '=', id).executeTakeFirst();
const row = await this.db()
.selectFrom('mail_ingest_candidates')
.selectAll()
.where('id', '=', id)
.executeTakeFirst();
return row ?? null;
}
@@ -208,7 +212,7 @@ export class MailIngestCandidatesRepository extends TrekRepository<MailIngestCan
return Number(row.n);
}
/** Whether a booking of this content was added to the trip from a mail and undone: it is not added on its own again. */
/** Whether a booking of this content went into the trip from a mail and was undone: never added again on its own. */
async wasUndoneInTrip(tripId: number, contentHash: string): Promise<boolean> {
const row = await this.db()
.selectFrom('mail_ingest_candidates')
@@ -328,7 +332,11 @@ export class MailIngestCandidatesRepository extends TrekRepository<MailIngestCan
if (confirmation) either.push(eb('confirmation_number', '=', confirmation));
if (startFrom && startTo) {
either.push(
eb.and([eb('type', '=', type), eb('reservation_time', '>=', startFrom), eb('reservation_time', '<=', startTo)]),
eb.and([
eb('type', '=', type),
eb('reservation_time', '>=', startFrom),
eb('reservation_time', '<=', startTo),
]),
);
}
// An empty list reads as false: a probe with neither names nothing.
@@ -30,7 +30,11 @@ export class MailIngestPrefsRepository extends TrekRepository<MailIngestPrefs> {
}
async findForUser(userId: number): Promise<MailIngestPrefsRow | null> {
const row = await this.db().selectFrom('mail_ingest_prefs').selectAll().where('user_id', '=', userId).executeTakeFirst();
const row = await this.db()
.selectFrom('mail_ingest_prefs')
.selectAll()
.where('user_id', '=', userId)
.executeTakeFirst();
return row ?? null;
}