1
0
Fork 0
mirror of https://github.com/wallabag/wallabag.git synced 2025-09-10 18:51:02 +00:00

Jump to Symfony 3.3 & update others deps

Also update tests urls
This commit is contained in:
Jeremy Benoist 2017-10-09 16:45:09 +02:00
parent ed5e175c20
commit f40c88eb1f
No known key found for this signature in database
GPG key ID: BCA73962457ACC3C
18 changed files with 52 additions and 30 deletions

View file

@ -46,7 +46,7 @@ class UserRestController extends WallabagRestController
public function putUserAction(Request $request)
{
if (!$this->getParameter('fosuser_registration') || !$this->get('craue_config')->get('api_user_registration')) {
$json = $this->get('serializer')->serialize(['error' => "Server doesn't allow registrations"], 'json');
$json = $this->get('jms_serializer')->serialize(['error' => "Server doesn't allow registrations"], 'json');
return (new JsonResponse())
->setJson($json)
@ -92,7 +92,7 @@ class UserRestController extends WallabagRestController
$errors['password'] = $this->translateErrors($data['plainPassword']['children']['first']['errors']);
}
$json = $this->get('serializer')->serialize(['error' => $errors], 'json');
$json = $this->get('jms_serializer')->serialize(['error' => $errors], 'json');
return (new JsonResponse())
->setJson($json)
@ -127,7 +127,7 @@ class UserRestController extends WallabagRestController
*/
private function sendUser(User $user, $group = 'user_api', $status = JsonResponse::HTTP_OK)
{
$json = $this->get('serializer')->serialize(
$json = $this->get('jms_serializer')->serialize(
$user,
'json',
SerializationContext::create()->setGroups([$group])