mirror of
https://github.com/signalapp/Signal-Desktop.git
synced 2025-12-24 20:26:24 +00:00
Add schema utils
This commit is contained in:
@@ -22,6 +22,7 @@ import { getCallIdFromEra } from '../../util/callDisposition';
|
||||
import { isValidUuid } from '../../util/isValidUuid';
|
||||
import { createDB, updateToVersion } from './helpers';
|
||||
import type { WritableDB, MessageType } from '../../sql/Interface';
|
||||
import { parsePartial } from '../../util/schemas';
|
||||
|
||||
describe('SQL/updateToSchemaVersion89', () => {
|
||||
let db: WritableDB;
|
||||
@@ -152,8 +153,8 @@ describe('SQL/updateToSchemaVersion89', () => {
|
||||
return db
|
||||
.prepare(selectHistoryQuery)
|
||||
.all()
|
||||
.map(row => {
|
||||
return callHistoryDetailsSchema.parse({
|
||||
.map((row: object) => {
|
||||
return parsePartial(callHistoryDetailsSchema, {
|
||||
...row,
|
||||
|
||||
// Not present at the time of migration, but required by zod
|
||||
|
||||
Reference in New Issue
Block a user