Total Complexity | 6 |
Total Lines | 33 |
Duplicated Lines | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
5 | class Auth |
||
6 | { |
||
7 | protected $auth; |
||
8 | |||
9 | public function __construct(PHPAuth $auth) |
||
12 | } |
||
13 | |||
14 | public function login($email, $password) |
||
17 | } |
||
18 | |||
19 | public function isLogged() |
||
20 | { |
||
21 | return $this->auth->isLogged(); |
||
22 | } |
||
23 | |||
24 | public function changePassword($currentPassword, $newPassword) |
||
25 | { |
||
26 | $uid = $this->auth->getCurrentUID(); |
||
27 | return $this->auth->changePassword($uid, $currentPassword, $newPassword); |
||
28 | } |
||
29 | |||
30 | public function sendEmail($email, $subject, $body) |
||
31 | { |
||
32 | // Implement email sending logic here, possibly using a separate email sending class or library |
||
33 | } |
||
34 | |||
35 | public function logout() |
||
38 | } |
||
39 | } |
||
40 |