emanueleminotto/temporary-email-validator

Symfony 验证器,用于临时电子邮件

1.0.0 2016-12-24 17:25 UTC

This package is auto-updated.

Last update: 2024-08-28 07:01:56 UTC


README

Latest Version on Packagist Software License Build Status Coverage Status Quality Score Total Downloads

Symfony 验证器,用于临时电子邮件,基于 andreis/disposable

安装

通过 Composer

$ composer require emanueleminotto/temporary-email-validator

用法

use EmanueleMinotto\TemporaryEmailValidator\NotTemporaryEmail;

$constraint = new NotTemporaryEmail();
// $constraint->message = your message

// use the validator to validate the value
$errorList = $this
    ->get('validator')
    ->validate('example@mail-temporaire.fr', $constraint);

$errorMessage = $errorList[0]->getMessage(); // The temporary email "example@mail-temporaire.fr" is not allowed.

变更日志

请参阅 CHANGELOG 了解最近更改的详细信息。

测试

$ composer test

贡献

请参阅 CONTRIBUTINGCONDUCT 了解详细信息。

安全

如果您发现任何安全问题,请通过电子邮件 minottoemanuele@gmail.com 联系,而不是使用问题跟踪器。

鸣谢

许可

MIT 许可证 (MIT)。有关更多信息,请参阅 许可文件