@@ -32,7 +32,7 @@ discard block |
||
32 | 32 | 'message' => sprintf( |
33 | 33 | '%d setting%s saved in the context: %s', |
34 | 34 | count($json['values']), |
35 | - count($json['values'])>1?'s':'', |
|
35 | + count($json['values']) > 1 ? 's' : '', |
|
36 | 36 | $json['context']) |
37 | 37 | ]]); |
38 | 38 | } catch (\Exception $e) { |
@@ -58,12 +58,12 @@ discard block |
||
58 | 58 | if (is_array($header)) { |
59 | 59 | $header = array_shift($header); |
60 | 60 | } |
61 | - if (strpos($header, 'application/json') === false) { |
|
61 | + if (strpos($header, 'application/json') === false) { |
|
62 | 62 | throw new InvalidRequestException('MCM save operation requires an application/json content type'); |
63 | 63 | } |
64 | 64 | $body = $request->getBody(); |
65 | 65 | $body->rewind(); |
66 | - $json = json_decode($body->getContents(), true); |
|
66 | + $json = json_decode($body->getContents(), true); |
|
67 | 67 | if ($json === false) { |
68 | 68 | throw new InvalidRequestException('Unable to read JSON string'); |
69 | 69 | } |