Skip to content

Commit

Permalink
fix: no foreign key select when cell value is NULL, closes #50
Browse files Browse the repository at this point in the history
  • Loading branch information
Fabio286 committed Apr 8, 2021
1 parent 55932fe commit 9f5ec02
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/renderer/components/ForeignKeySelect.vue
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ export default {
}),
isValidDefault () {
if (!this.foreignList.length) return true;
return this.foreignList.some(foreign => foreign.foreign_column.toString() === this.value.toString());
return this.value === null || this.foreignList.some(foreign => foreign.foreign_column.toString() === this.value.toString());
}
},
async created () {
Expand Down

0 comments on commit 9f5ec02

Please sign in to comment.