1
0
mirror of https://github.com/fzaninotto/Faker.git synced 2025-03-24 01:09:50 +01:00

Remove spaces in others generated emails.

This commit is contained in:
Tristan LEMARTINEL 2012-12-21 15:28:12 +01:00
parent 5b1075c13f
commit f8f12a38bc

View File

@ -38,7 +38,7 @@ class Internet extends \Faker\Provider\Base
*/
public function safeEmail()
{
return $this->userName() . '@example.' . static::randomElement(static::$safeEmailTld);
return preg_replace('/\s/', '', $this->userName() . '@example.' . static::randomElement(static::$safeEmailTld));
}
/**
@ -46,7 +46,7 @@ class Internet extends \Faker\Provider\Base
*/
public function freeEmail()
{
return $this->userName() . '@' . static::freeEmailDomain();
return preg_replace('/\s/', '', $this->userName() . '@' . static::freeEmailDomain());
}
/**
@ -54,7 +54,7 @@ class Internet extends \Faker\Provider\Base
*/
public function companyEmail()
{
return $this->userName() . '@' . $this->domainName();
return preg_replace('/\s/', '', $this->userName() . '@' . $this->domainName());
}
/**