Skip to content

Commit

Permalink
fix: added proper check to test for map type
Browse files Browse the repository at this point in the history
Signed-off-by: Muskan Bararia <[email protected]>
  • Loading branch information
Muskan Bararia committed Nov 14, 2023
1 parent d86d203 commit b030c98
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/concerto-core/lib/decoratorextractor.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@

const ModelManager = require('./modelmanager');
const ModelUtil = require('./modelutil');
const { MetaModelNamespace } = require('@accordproject/concerto-metamodel');

/**
* Utility functions to work with
Expand Down Expand Up @@ -331,7 +332,7 @@ class DecoratorExtractor {
if (this.removeDecoratorsFromModel){
decl.decorators = undefined;
}
if (decl.$class.endsWith('.MapDeclaration')) {
if (decl.$class === `${MetaModelNamespace}.MapDeclaration`) {
const processedMapDecl = this.processMapDeclaration(decl, namespace);
decl = processedMapDecl;
}
Expand Down

0 comments on commit b030c98

Please sign in to comment.