Merge branch 'master' of https://github.com/brkcvn/akaunting into code-clean
This commit is contained in:
commit
aba0bc9356
@ -11,7 +11,8 @@ Feel free to report security issues based on the following chart.
|
||||
| 1.2.x | :x: |
|
||||
| 1.3.x | :x: |
|
||||
| 2.0.x | :x: |
|
||||
| 2.1.x | :white_check_mark: |
|
||||
| 2.1.x | :x: |
|
||||
| 3.0.x | :white_check_mark: |
|
||||
|
||||
## Reporting a Vulnerability
|
||||
|
||||
|
@ -34,11 +34,16 @@ class Profile extends FormRequest
|
||||
. ',deleted_at,NULL';
|
||||
}
|
||||
|
||||
$change_password = $this->request->get('change_password') == true || $this->request->get('change_password') != null;
|
||||
|
||||
$current_password = $change_password ? '|current_password' : '';
|
||||
$password = $change_password ? '|confirmed' : '';
|
||||
|
||||
return [
|
||||
'name' => 'required|string',
|
||||
'email' => $email,
|
||||
'current_password' => 'required_if:change_password,true|current_password',
|
||||
'password' => 'required_if:change_password,true|confirmed',
|
||||
'current_password' => 'required_if:change_password,true' . $current_password,
|
||||
'password' => 'required_if:change_password,true' . $password,
|
||||
'picture' => $picture,
|
||||
];
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user