Skip to content

Commit

Permalink
Trim quotes from reference properties
Browse files Browse the repository at this point in the history
  • Loading branch information
kristiandupont committed Nov 3, 2020
1 parent db1f278 commit 59424ad
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions src/extract-columns.js
Original file line number Diff line number Diff line change
Expand Up @@ -74,10 +74,13 @@ FROM
n: 'SET NULL',
d: 'SET DEFAULT',
};

const trim = (s) => s.replace(/^"(.*)"$/, '$1');

return {
schema,
table,
column,
schema: trim(schema),
table: trim(table),
column: trim(column),
onDelete: updateActionMap[confupdtype],
onUpdate: updateActionMap[confdeltype],
};
Expand Down

0 comments on commit 59424ad

Please sign in to comment.