Merge pull request #39 from deguif/patch-5

Simplified PHP code
This commit is contained in:
Martin Cech 2016-06-17 10:25:43 -04:00 committed by GitHub
commit fc087ca922

View File

@ -24,8 +24,7 @@ else:
PHP contributed by @txt3rob
```php
function is_temp_mail($mail) {
$list = file_get_contents ('disposable_email_blacklist.conf');
$mail_domains_ko = explode("\n", $list);
$mail_domains_ko = file('disposable_email_blacklist.conf', FILE_IGNORE_NEW_LINES | FILE_SKIP_EMPTY_LINES);
foreach($mail_domains_ko as $ko_mail) {
list($mail_address, $mail_domain) = explode('@',$mail);
if(strcasecmp($mail_domain, $ko_mail) == 0){