Skip to content

Commit 5ecef99

Browse files
Merge pull request #245 from themost-framework/fix-association-callback
Throw association error if expand association is missing or is not correctly set
2 parents 0de2774 + ba5edd2 commit 5ecef99

3 files changed

Lines changed: 4 additions & 2 deletions

File tree

data-queryable.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2744,6 +2744,8 @@ function afterExecute_(result, callback) {
27442744
return cb(err);
27452745
});
27462746
}
2747+
// throw association error if mapping is not set
2748+
return cb(new DataError('EASSOC', sprintf('Data association mapping (%s) for %s cannot be determined.', mapping.refersTo, self.model.name)));
27472749
}
27482750
else {
27492751
return cb(new Error('Not yet implemented'));

package-lock.json

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@themost/data",
3-
"version": "2.6.98",
3+
"version": "2.6.99",
44
"description": "MOST Web Framework Codename Blueshift - Data module",
55
"main": "index.js",
66
"types": "index.d.ts",

0 commit comments

Comments
 (0)