TMLAction action = context.getActionByID(actionLocator.getId(), actionLocator.getDbkey());
if (action == null) {
throw new EvaluatorException("Could not retrieve action for ID '" + actionID + "'");
}
TMLScriptRootScope rootScope = fetchRootScope(cx);
// Call action
Object actionResult;
try {
actionResult = context.callCustomAction(action, actionArgs, rootScope.getData().getUnwrappedGlobalScopeObjects());
}
catch (WGAPIException e) {
throw Context.throwAsScriptRuntimeEx(e);
}