Skip to content

Commit

Permalink
feat(database): return old title
Browse files Browse the repository at this point in the history
  • Loading branch information
yjl9903 committed Jan 29, 2024
1 parent 87fb32d commit 9d0c9a9
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion packages/database/src/operations/dmhy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ export async function updateDmhyResources(database: Database, fetchedResources:
provider: string;
providerId: string;
title: string;
oldTitle?: string;
}> = [];
for (const latest of res) {
const found = await database.query.resources.findFirst({
Expand Down Expand Up @@ -90,7 +91,8 @@ export async function updateDmhyResources(database: Database, fetchedResources:
operation: 'rename',
provider: updated[0].provider,
providerId: updated[0].providerId,
title: updated[0].title
title: updated[0].title,
oldTitle: found.title
});
}
}
Expand Down

0 comments on commit 9d0c9a9

Please sign in to comment.