Skip to content
This repository has been archived by the owner on Mar 6, 2023. It is now read-only.

Commit

Permalink
Merge pull request #6 from amtl/node6
Browse files Browse the repository at this point in the history
update remodel lib so it works with node 6
  • Loading branch information
andrewcuneo committed May 5, 2016
2 parents 7a28185 + dc93346 commit 004d510
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 10 deletions.
Expand Up @@ -61,18 +61,18 @@ function parse(fileInput) {
if (parsedType == null) {
throw "parsed type came back as null";
}
return {
errorReason: null,
isValid: true,
type: parsedType
};
} catch (e) {
return {
errorReason:e.message,
isValid:false,
type: null
};
}
return {
errorReason: null,
isValid: true,
type: parsedType
};
}

module.exports = {
Expand Down
10 changes: 5 additions & 5 deletions src/js/object-mona-parser/value-object/value-object-parser.js
Expand Up @@ -18,6 +18,11 @@ const parseCommon = require('../object-parser-common');
function parse(fileInput) {
try {
const parsedType = mona.parse(parseCommon.parseNamedAttributeGroupWithIncludes(), fileInput);
return {
errorReason: null,
isValid: true,
foundType: parsedType
};
} catch (e) {
return {
errorReason:e.message,
Expand All @@ -26,11 +31,6 @@ function parse(fileInput) {
};
}

return {
errorReason: null,
isValid: true,
foundType: parsedType
};
}

module.exports = {
Expand Down

0 comments on commit 004d510

Please sign in to comment.