Boolean removeOld = (Boolean) context.get("removeOld");
//Locale locale = (Locale) context.get("locale");
if (removeOld != null && removeOld.booleanValue()) {
try {
delegator.removeByAnd("OrderRole", UtilMisc.toMap("orderId", orderId, "roleTypeId", roleTypeId));
} catch (GenericEntityException e) {
result.put(ModelService.RESPONSE_MESSAGE, ModelService.RESPOND_ERROR);
result.put(ModelService.ERROR_MESSAGE, "ERROR: Could not remove old roles (" + e.getMessage() + ").");
return result;
}