Skip to content

Instantly share code, notes, and snippets.

@glye
Last active September 28, 2015 11:45
Show Gist options
  • Save glye/8c005203f0a2342b9f11 to your computer and use it in GitHub Desktop.
Save glye/8c005203f0a2342b9f11 to your computer and use it in GitHub Desktop.
RoleAssignInput hack for EZP-24700: Role assignment CRUD
--- a/eZ/Publish/Core/REST/Server/Input/Parser/RoleAssignInput.php
+++ b/eZ/Publish/Core/REST/Server/Input/Parser/RoleAssignInput.php
@@ -48,6 +48,8 @@ class RoleAssignInput extends BaseParser
*/
public function parse(array $data, ParsingDispatcher $parsingDispatcher)
{
+ $data = $data['Role']['document'];
+
if (!array_key_exists('Role', $data)) {
throw new Exceptions\Parser("Missing 'Role' element for RoleAssignInput.");
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment