summaryrefslogtreecommitdiffstats
path: root/modules-available/dozmod
diff options
context:
space:
mode:
authorSimon Rettberg2017-12-16 18:33:16 +0100
committerSimon Rettberg2017-12-16 18:33:16 +0100
commitcd55ead3e2810e209b726faca12fa749f6875d0f (patch)
tree94b2f29b023e8a0c5100e1d06c974c3c04f890fd /modules-available/dozmod
parentMerge branch 'permission-manager' of openslx.org:openslx-ng/slx-admin into pe... (diff)
downloadslx-admin-cd55ead3e2810e209b726faca12fa749f6875d0f.tar.gz
slx-admin-cd55ead3e2810e209b726faca12fa749f6875d0f.tar.xz
slx-admin-cd55ead3e2810e209b726faca12fa749f6875d0f.zip
Fix A LOT of type problems, logic flaws, uninitialized variables etc.
Most of them were found by phpstorm, so I put in some time and went through the list, fixing quite a bunch of them.
Diffstat (limited to 'modules-available/dozmod')
-rw-r--r--modules-available/dozmod/inc/pagedozmodlog.inc.php4
-rw-r--r--modules-available/dozmod/templates/orglist.html1
-rw-r--r--modules-available/dozmod/templates/userlist.html1
3 files changed, 4 insertions, 2 deletions
diff --git a/modules-available/dozmod/inc/pagedozmodlog.inc.php b/modules-available/dozmod/inc/pagedozmodlog.inc.php
index 957abd2f..80441cd1 100644
--- a/modules-available/dozmod/inc/pagedozmodlog.inc.php
+++ b/modules-available/dozmod/inc/pagedozmodlog.inc.php
@@ -48,7 +48,7 @@ class Page_dozmod_log extends Page
. ' WHERE userid = :uuid'
. ' LIMIT 1', array('uuid' => $this->uuid));
if ($user === false) {
- Message:addError('unknown-userid', $this->uuid);
+ Message::addError('unknown-userid', $this->uuid);
Util::redirect('?do=dozmod&section=actionlog');
}
// Mangle date and render
@@ -70,7 +70,7 @@ class Page_dozmod_log extends Page
// We have to guess what kind of target it is
if (!$this->addImageHeader()
&& !$this->addLectureHeader()) {
- Message:addError('unknown-targetid', $this->uuid);
+ Message::addError('unknown-targetid', $this->uuid);
// Keep going, there might still be log entries for a deleted uuid
}
diff --git a/modules-available/dozmod/templates/orglist.html b/modules-available/dozmod/templates/orglist.html
index 5224c962..33db955a 100644
--- a/modules-available/dozmod/templates/orglist.html
+++ b/modules-available/dozmod/templates/orglist.html
@@ -33,6 +33,7 @@
function seto(action, el, orgid) {
var box = $(el);
+ var $notification;
box = box.parent();
var v = el.checked ? '1' : '0';
var old = el.checked == true;
diff --git a/modules-available/dozmod/templates/userlist.html b/modules-available/dozmod/templates/userlist.html
index 378a2be1..b8080b44 100644
--- a/modules-available/dozmod/templates/userlist.html
+++ b/modules-available/dozmod/templates/userlist.html
@@ -56,6 +56,7 @@
function setu(action, el, uid) {
var box = $(el);
+ var $notification;
box = box.parent();
var v = el.checked ? '1' : '0';
var old = el.checked == true;