Skip to content

Commit

Permalink
fix: null referance exception
Browse files Browse the repository at this point in the history
  • Loading branch information
MichaelTaylor3D committed Sep 13, 2022
1 parent 9baf7f6 commit 08f2144
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
8 changes: 4 additions & 4 deletions src/models/organizations/organizations.modeltypes.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,10 @@ module.exports = {
defaultValue: false,
},
metadata: {
type: Sequelize.STRING,
allowNull: true,
defaultValue: {},
},
type: Sequelize.STRING,
allowNull: true,
defaultValue: {},
},
createdAt: Sequelize.DATE,
updatedAt: Sequelize.DATE,
};
4 changes: 2 additions & 2 deletions src/models/staging/staging.model.js
Original file line number Diff line number Diff line change
Expand Up @@ -96,8 +96,8 @@ class Staging extends Model {

// Each child record for the maker needs the new projectId
projectChildRecords.forEach((childRecordSet) => {
if (projectChildRecords[childRecordSet]) {
projectChildRecords[childRecordSet].forEach((childRecord) => {
if (makerProjectRecord[childRecordSet]) {
makerProjectRecord[childRecordSet].forEach((childRecord) => {
childRecord.warehouseProjectId = newMakerWarehouseProjectId;
});
}
Expand Down

0 comments on commit 08f2144

Please sign in to comment.