Добавлен запрос пароля для запроса инициализации смены email

This commit is contained in:
ErickSkrauch 2017-10-13 18:43:24 +03:00
parent 81bdb1f2af
commit c855cdb394

View File

@ -130,6 +130,16 @@ class TestData {
public function beforeAccountEmailVerification(Request $request): ?array {
$httpAuth = $request->getHeaders()->get('authorization');
if ($httpAuth === 'Bearer dummy_token') {
$password = $request->post('password');
if (empty($password)) {
return [
'success' => false,
'errors' => [
'password' => 'error.password_required',
],
];
}
return [
'success' => true,
];