Skip to content

Commit

Permalink
Fix mapping script global variable types.
Browse files Browse the repository at this point in the history
  • Loading branch information
pavelhoral committed Aug 12, 2024
1 parent 69a28d0 commit 18f9620
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -746,7 +746,7 @@ private void execScript(String type, Script script, JsonValue oldTarget) throws
Map<String, Object> scope = new HashMap<String, Object>();
scope.put("context", context);
scope.put("linkQualifier", getLinkQualifier());
scope.put("mappingConfig", objectMapping.getConfig());
scope.put("mappingConfig", objectMapping.getConfig().asMap());
String sourceId = getSourceObjectId();
String targetId = getTargetObjectId();
// TODO: Once script engine can do on-demand get replace these forced loads
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,11 @@ def syncContext = context.containsContext(SyncContext.class) \
? context.asContext(SyncContext.class)
: null;

def mappingSource = mappingConfig.source.getObject() as String
def mappingSource = mappingConfig.source as String
def sourceObject = source as JsonValue
def oldSource = oldSource as JsonValue

mappingName = mappingConfig.name.getObject() as String
def mappingName = mappingConfig.name as String

try {
if (!mappingSource.equals("managed/user") && syncContext == null) {
Expand Down

0 comments on commit 18f9620

Please sign in to comment.