Skip to content
Snippets Groups Projects
Commit a73ec9ba authored by Quentin Ribac's avatar Quentin Ribac
Browse files

FIX #17773 TIME 0:30 cleaning maileva uri and authUri when saving them

parent 5690a5d0
No related branches found
No related tags found
No related merge requests found
...@@ -188,6 +188,11 @@ class ConfigurationController ...@@ -188,6 +188,11 @@ class ConfigurationController
} elseif (!Validator::boolType()->validate($data['enabled'] ?? null)) { } elseif (!Validator::boolType()->validate($data['enabled'] ?? null)) {
return $response->withStatus(400)->withJson(['errors' => "Body enabled is not set or not a boolean"]); return $response->withStatus(400)->withJson(['errors' => "Body enabled is not set or not a boolean"]);
} }
$data = [
'uri' => rtrim($data['uri'], '/'),
'authUri' => rtrim($data['authUri'], '/'),
'enabled' => $data['enabled'],
];
} elseif ($args['privilege'] == 'admin_organization_email_signatures') { } elseif ($args['privilege'] == 'admin_organization_email_signatures') {
if (!Validator::notEmpty()->arrayType()->validate($data)) { if (!Validator::notEmpty()->arrayType()->validate($data)) {
return $response->withStatus(400)->withJson(['errors' => 'Body is empty or not an array']); return $response->withStatus(400)->withJson(['errors' => 'Body is empty or not an array']);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment