mirror of
https://gitlab.com/animath/si/plateforme.git
synced 2024-12-24 17:42:23 +00:00
Le premier inscrit est administrateur
This commit is contained in:
parent
9213258df4
commit
a36a4cc728
@ -73,6 +73,9 @@ class NewUser
|
||||
}
|
||||
}
|
||||
|
||||
if (sizeof(User::getAllUsers()) == 0)
|
||||
$this->role = Role::ADMIN;
|
||||
|
||||
$this->confirm_email_token = genRandomPhrase(64);
|
||||
}
|
||||
|
||||
|
@ -117,7 +117,7 @@
|
||||
</div>
|
||||
<?php }
|
||||
|
||||
if (getallheaders()["X-Real-Ip"] != "185.230.76.133") {
|
||||
if (!isset($_SESSION["user"]) && $view != "server_files/controllers/connexion.php") {
|
||||
echo "<div style=\"text-align: center;\" class=\"alert alert-success\"><h1>Cette plateforme ouvrira le 22 janvier 2020 ! :)</h1></div>";
|
||||
require_once "footer.php";
|
||||
}
|
Loading…
Reference in New Issue
Block a user