#215 single primary key is always unique
This commit is contained in:
parent
bef61595af
commit
35c7e35f74
@ -424,6 +424,12 @@ export default abstract class AbstractDriver {
|
||||
.forEach(col => {
|
||||
// eslint-disable-next-line no-param-reassign
|
||||
col.primary = true;
|
||||
if (
|
||||
primaryIndex!.columns.length === 1 &&
|
||||
col.options.unique
|
||||
) {
|
||||
delete col.options.unique;
|
||||
}
|
||||
});
|
||||
if (
|
||||
!entity.columns.some(v => {
|
||||
|
Loading…
Reference in New Issue
Block a user