summaryrefslogtreecommitdiff
path: root/modules/user/controllers
diff options
context:
space:
mode:
Diffstat (limited to 'modules/user/controllers')
-rw-r--r--modules/user/controllers/login.php2
-rw-r--r--modules/user/controllers/logout.php2
2 files changed, 4 insertions, 0 deletions
diff --git a/modules/user/controllers/login.php b/modules/user/controllers/login.php
index 3c1d6542..60ac16c0 100644
--- a/modules/user/controllers/login.php
+++ b/modules/user/controllers/login.php
@@ -30,6 +30,8 @@ class Login_Controller extends Controller {
if ($user->loaded &&
user::is_correct_password($user, $group->password->value)) {
user::login($user);
+ log::add("user", "User $user->name logged in",
+ log::INFO, html::anchor("user/$user->id", $user->name));
if ($continue = $this->input->get("continue")) {
url::redirect($continue);
}
diff --git a/modules/user/controllers/logout.php b/modules/user/controllers/logout.php
index 60f9ee50..f0feb48d 100644
--- a/modules/user/controllers/logout.php
+++ b/modules/user/controllers/logout.php
@@ -20,6 +20,8 @@
class Logout_Controller extends Controller {
public function index() {
user::logout();
+ log::add("user", "User $user->name logged out",
+ log::INFO, html::anchor("user/$user->id", $user->name));
if ($this->input->get("continue")) {
url::redirect($this->input->get("continue"));
}