Skip to content

Commit

Permalink
Update include-through.js
Browse files Browse the repository at this point in the history
  • Loading branch information
Selichio authored Apr 13, 2018
1 parent 3ff8ba3 commit 9d28d80
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion include-through.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ module.exports = function(Model, options) {
function controller(ctx, unused, next) {
if (ctx.methodString.indexOf('prototype.__get__') !== -1) {
// the original version
var relationName = ctx.methodString.match(/__([a-z\d]+)$/)[1];
var relationName = ctx.methodString.match(/__([a-zA-Z]+)$/)[1];
var partialResult = JSON.parse(JSON.stringify(ctx.result));
injectIncludes(ctx, partialResult, relationName).then(function(partialResult) {
ctx.result = partialResult;
Expand Down

0 comments on commit 9d28d80

Please sign in to comment.