summaryrefslogtreecommitdiffstats
path: root/Core/User/User.php
diff options
context:
space:
mode:
Diffstat (limited to 'Core/User/User.php')
-rw-r--r--Core/User/User.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/Core/User/User.php b/Core/User/User.php
index ea2c6a4..86f1acd 100644
--- a/Core/User/User.php
+++ b/Core/User/User.php
@@ -30,7 +30,7 @@ final class User implements AdvancedUserInterface
public function __construct($username, $password, array $roles = array(), $enabled = true, $userNonExpired = true, $credentialsNonExpired = true, $userNonLocked = true)
{
- if (empty($username)) {
+ if ('' === $username || null === $username) {
throw new \InvalidArgumentException('The username cannot be empty.');
}