Merge pull request #175 from SergiX44/analysis-1bWrP1

Apply fixes from StyleCI
This commit is contained in:
Sergio Brighenti 2020-04-04 19:29:29 +02:00 committed by GitHub
commit b2342f4acb
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 6 deletions

View file

@ -8,10 +8,8 @@ use App\Web\Session;
use App\Web\ValidationHelper; use App\Web\ValidationHelper;
use Psr\Http\Message\ServerRequestInterface as Request; use Psr\Http\Message\ServerRequestInterface as Request;
abstract class AuthController extends Controller abstract class AuthController extends Controller
{ {
protected function checkRecaptcha(ValidationHelper $validator, Request $request) protected function checkRecaptcha(ValidationHelper $validator, Request $request)
{ {
$validator->callIf($this->getSetting('recaptcha_enabled') === 'on', function (Session $session) use (&$request) { $validator->callIf($this->getSetting('recaptcha_enabled') === 'on', function (Session $session) use (&$request) {
@ -65,4 +63,4 @@ abstract class AuthController extends Controller
return $bindString; return $bindString;
} }
} }

View file

@ -3,7 +3,6 @@
namespace App\Web; namespace App\Web;
class ValidationHelper class ValidationHelper
{ {
/** /**
@ -31,7 +30,6 @@ class ValidationHelper
if (!$this->failed && $condition) { if (!$this->failed && $condition) {
$this->failed = true; $this->failed = true;
$this->session->alert(lang($alert), $type); $this->session->alert(lang($alert), $type);
} }
return $this; return $this;
@ -65,4 +63,4 @@ class ValidationHelper
{ {
return $this->failed; return $this->failed;
} }
} }