Skip to content

Commit

Permalink
feat: export db.fromDB
Browse files Browse the repository at this point in the history
  • Loading branch information
prigaux committed Oct 2, 2024
1 parent b6caf77 commit 97948a9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion server/db.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ export const error_codes = {
function _id(id: string = undefined) {
return new mongodb.ObjectID(id);
}
function fromDB(sv_: any) {
export function fromDB(sv_: any) {
return renameKey(sv_, '_id', 'id') as sv;
}
function toDB<T extends { id?: string }>(sv: T) {
Expand Down

0 comments on commit 97948a9

Please sign in to comment.