When an error is thrown by services, the handleException method is called in RESTServer.inc. This in turn performs a drupal_alter to allow other modules to adjust the error code, message and data,

drupal_alter('rest_server_execute_errors', $error_alter_array, $controller, $arguments);

However this fails to alter the actual code/message/data returned as these exist in the $exception object which is not modified. This appears to have changed from a recent version.

Comments

N1ghteyes created an issue. See original summary.

N1ghteyes’s picture

Priority: Major » Normal
Status: Active » Closed (works as designed)

On further testing, its not a bug, just a slightly altered implementation which broke existing code.