Rename Core\Validators
This commit is contained in:
parent
b162126a22
commit
e8157cc802
5 changed files with 9 additions and 9 deletions
|
@ -5,7 +5,7 @@ namespace ForkBB\Core;
|
|||
use ForkBB\Core\Container;
|
||||
use RuntimeException;
|
||||
|
||||
abstract class Validators
|
||||
abstract class RulesValidator
|
||||
{
|
||||
/**
|
||||
* Контейнер
|
|
@ -4,7 +4,7 @@ namespace ForkBB\Core;
|
|||
|
||||
use ForkBB\Core\Container;
|
||||
use ForkBB\Core\File;
|
||||
use ForkBB\Core\Validators;
|
||||
use ForkBB\Core\RulesValidator;
|
||||
use RuntimeException;
|
||||
use function \ForkBB\__;
|
||||
|
||||
|
@ -169,7 +169,7 @@ class Validator
|
|||
$validator = null;
|
||||
}
|
||||
|
||||
if ($validator instanceof Validators) {
|
||||
if ($validator instanceof RulesValidator) {
|
||||
$this->validators[$vs[0]] = [$validator, $vs[0]];
|
||||
} else {
|
||||
throw new RuntimeException($vs[0] . ' validator not found');
|
||||
|
|
|
@ -2,12 +2,12 @@
|
|||
|
||||
namespace ForkBB\Models\Validators;
|
||||
|
||||
use ForkBB\Core\RulesValidator;
|
||||
use ForkBB\Core\Validator;
|
||||
use ForkBB\Core\Validators;
|
||||
use ForkBB\Models\User\Model as User;
|
||||
use function \ForkBB\__;
|
||||
|
||||
class Email extends Validators
|
||||
class Email extends RulesValidator
|
||||
{
|
||||
/**
|
||||
* Проверяет email
|
||||
|
|
|
@ -2,10 +2,10 @@
|
|||
|
||||
namespace ForkBB\Models\Validators;
|
||||
|
||||
use ForkBB\Core\RulesValidator;
|
||||
use ForkBB\Core\Validator;
|
||||
use ForkBB\Core\Validators;
|
||||
|
||||
class NoURL extends Validators
|
||||
class NoURL extends RulesValidator
|
||||
{
|
||||
/**
|
||||
* Проверяет значение на отсутствие ссылки, если пользователю запрещено использовать ссылки или включен флаг принудительной проверки
|
||||
|
|
|
@ -2,12 +2,12 @@
|
|||
|
||||
namespace ForkBB\Models\Validators;
|
||||
|
||||
use ForkBB\Core\RulesValidator;
|
||||
use ForkBB\Core\Validator;
|
||||
use ForkBB\Core\Validators;
|
||||
use ForkBB\Models\User\Model as User;
|
||||
use function \ForkBB\__;
|
||||
|
||||
class Username extends Validators
|
||||
class Username extends RulesValidator
|
||||
{
|
||||
/**
|
||||
* Проверяет имя пользователя
|
||||
|
|
Loading…
Add table
Reference in a new issue