Dependency injection on migration functions (uid parameter).
This commit is contained in:
1 parent
2c64cd1d27
commit
3942e0535c
7 files changed
+23
-24
No files matched your search
+6
-7
@@ -78,13 +78,12 @@ class User {
|
||||
return false;
|
||||
}
|
||||
$this->password = $data['password1'];
|
||||
if (!isAdmin()) {
|
||||
switch (checkForumUsername($data['username'], $this->password)) {
|
||||
case "wrong-password" :
|
||||
notify("Brukernavnet er allerede i bruk på forumet. " . "Om du selv har dette brukernavnet må du oppgi " . "riktig passord.");
|
||||
$this->id = -1;
|
||||
return false;
|
||||
}
|
||||
|
||||
/* Does the username chosen exist in the forum allready? */
|
||||
if (!isAdmin() && checkForumUsername($data['username'], $this->password) == "wrong-password") {
|
||||
notify("Brukernavnet er allerede i bruk på forumet. Om du selv har dette brukernavnet må du oppgi riktig passord.");
|
||||
$this->id = -1;
|
||||
return false;
|
||||
}
|
||||
|
||||
$this->addresstype = isset ($data['addresstype']) ? "int" : "no";
|
||||
|
||||
Reference in new issue
Block a user