Skip to content

Commit

Permalink
Formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
jede committed Jan 26, 2025
1 parent ce3266e commit c367123
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/yayson/adapters/sequelize.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,7 @@ class SequelizeAdapter extends Adapter {
static id(model) {
// Retain backwards compatibility with older sequelize versions
const pkFields =
model.constructor && model.constructor.primaryKeys ?
Object.keys(model.constructor.primaryKeys) :
['id']
model.constructor && model.constructor.primaryKeys ? Object.keys(model.constructor.primaryKeys) : ['id']

if (pkFields.length > 1) {
throw new Error(
Expand Down

0 comments on commit c367123

Please sign in to comment.