summaryrefslogtreecommitdiff
path: root/includes/model/Shifts_model.php
diff options
context:
space:
mode:
authorIgor Scheller <igor.scheller@igorshp.de>2018-10-08 21:15:56 +0200
committermsquare <msquare@notrademark.de>2018-10-31 13:43:23 +0100
commit2dcb7cc2de448c664bbc9a7112f9cb13dc15c516 (patch)
treee409cf77e97c91ff27b0e61f2a982519fdfdf76f /includes/model/Shifts_model.php
parentd15946df2dfb0ae2f0ca9371e5c8071df91ab45a (diff)
Replaced some global `$user` variables
Diffstat (limited to 'includes/model/Shifts_model.php')
-rw-r--r--includes/model/Shifts_model.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/includes/model/Shifts_model.php b/includes/model/Shifts_model.php
index 74facc0a..30ce5a97 100644
--- a/includes/model/Shifts_model.php
+++ b/includes/model/Shifts_model.php
@@ -518,7 +518,7 @@ function Shift_delete($shift_id)
*/
function Shift_update($shift)
{
- global $user;
+ $user = Auth()->user();
$shift['name'] = ShiftType($shift['shifttype_id'])['name'];
mail_shift_change(Shift($shift['SID']), $shift);
@@ -543,7 +543,7 @@ function Shift_update($shift)
$shift['title'],
$shift['URL'],
$shift['PSID'],
- $user['UID'],
+ $user->id,
time(),
$shift['SID']
]