summaryrefslogtreecommitdiff
path: root/includes/controller/shifttypes_controller.php
diff options
context:
space:
mode:
authorIgor Scheller <igor.scheller@igorshp.de>2018-08-20 20:58:51 +0200
committerIgor Scheller <igor.scheller@igorshp.de>2018-08-20 21:07:57 +0200
commitd6c8f1a61475fefa9594141aaf12a28d220bdaf8 (patch)
tree905051fdb1307f947c3a3a7be240609f8bc00e59 /includes/controller/shifttypes_controller.php
parentbf6efe532c8f2de84e95b090911280a9b1b61ce8 (diff)
parent2f41b9e4418def9b69cf237312bc592364585025 (diff)
Merge branch 'master' to 'rebuild-database'
Diffstat (limited to 'includes/controller/shifttypes_controller.php')
-rw-r--r--includes/controller/shifttypes_controller.php11
1 files changed, 5 insertions, 6 deletions
diff --git a/includes/controller/shifttypes_controller.php b/includes/controller/shifttypes_controller.php
index 4e7cd92c..bc9c5c52 100644
--- a/includes/controller/shifttypes_controller.php
+++ b/includes/controller/shifttypes_controller.php
@@ -22,8 +22,7 @@ function shifttype_delete_controller()
}
$shifttype = ShiftType($request->input('shifttype_id'));
-
- if ($shifttype == null) {
+ if (empty($shifttype)) {
redirect(page_link_to('shifttypes'));
}
@@ -58,7 +57,7 @@ function shifttype_edit_controller()
if ($request->has('shifttype_id')) {
$shifttype = ShiftType($request->input('shifttype_id'));
- if ($shifttype == null) {
+ if (empty($shifttype)) {
error(_('Shifttype not found.'));
redirect(page_link_to('shifttypes'));
}
@@ -120,12 +119,12 @@ function shifttype_controller()
redirect(page_link_to('shifttypes'));
}
$shifttype = ShiftType($request->input('shifttype_id'));
- if ($shifttype == null) {
+ if (empty($shifttype)) {
redirect(page_link_to('shifttypes'));
}
- $angeltype = null;
- if ($shifttype['angeltype_id'] != null) {
+ $angeltype = [];
+ if (!empty($shifttype['angeltype_id'])) {
$angeltype = AngelType($shifttype['angeltype_id']);
}