mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-07 20:08:53 +00:00
[ticket/11720] Do not call $captcha->validate if $captcha is not set
PHPBB3-11566 changed big parts of code. Unfortunately, a call to $captcha->validate was added that is being called even if $captcha hasn't been initialized. This change will fix this issue. PHPBB3-11720
This commit is contained in:
parent
036a4188f3
commit
56df3fd8ca
1 changed files with 6 additions and 3 deletions
|
@ -146,10 +146,13 @@ $s_hidden_fields = '';
|
||||||
// Submit report?
|
// Submit report?
|
||||||
if ($submit && $reason_id)
|
if ($submit && $reason_id)
|
||||||
{
|
{
|
||||||
$visual_confirmation_response = $captcha->validate();
|
if (isset($captcha))
|
||||||
if ($visual_confirmation_response)
|
|
||||||
{
|
{
|
||||||
$error[] = $visual_confirmation_response;
|
$visual_confirmation_response = $captcha->validate();
|
||||||
|
if ($visual_confirmation_response)
|
||||||
|
{
|
||||||
|
$error[] = $visual_confirmation_response;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
$sql = 'SELECT *
|
$sql = 'SELECT *
|
||||||
|
|
Loading…
Add table
Reference in a new issue