Deploy new admin user did not use resultset

This commit is contained in:
Oliver Gorwits
2014-02-17 13:18:15 +00:00
parent 62acb8b4c0
commit a2c25cd478
4 changed files with 10 additions and 4 deletions

View File

@@ -122,8 +122,8 @@ sub _make_password {
}
}
my $users = schema('netdisco')->resultset('User')->search({-bool => 'admin'});
if ($users->count == 0) {
my $users = schema('netdisco')->resultset('User');
if ($users->search({-bool => 'admin'})->count == 0) {
say '';
print color 'bold green';
say 'We need to create a user for inital login. This user will be a full Administrator.';