auth: user method to retrieve configured email
[minimedit.git] / auth.inc.php
index 52cd4c1e29ababbce4ae3729f652617a247935d0..4d9b29e2a297f00e05184cdb954e54c802d1c958 100644 (file)
@@ -32,6 +32,11 @@ class User
                return $this->name ?: $this->login;
        }
 
+       function email()
+       {
+               return rtrim(@file_get_contents("{$this->dir}/email.txt"));
+       }
+
        function admin()
        {
                return @file_exists("{$this->dir}/.admin");