if (!dataMan.existsMetadata(iLocalId))
throw new IllegalArgumentException("Metadata not found --> " + id);
//--- only allow the owner of the record to set its status
if (!am.isOwner(context, id)) {
throw new UnAuthorizedException("Only the owner of the metadata can set the status. User is not the owner of the metadata", null);
}
String status = Util.getParam(params, Params.STATUS);
String changeMessage = Util.getParam(params, Params.CHANGE_MESSAGE);
ISODate changeDate = new ISODate();