diff options
author | raimund-schluessler <raimund.schluessler@googlemail.com> | 2014-07-15 20:58:51 +0400 |
---|---|---|
committer | raimund-schluessler <raimund.schluessler@googlemail.com> | 2014-07-15 20:58:51 +0400 |
commit | 5311339019ce5d6361ef614576ffb56ff29e8d34 (patch) | |
tree | dc1799138eda040b92f060db9fe873e97e795fe2 /lib | |
parent | 00968145240585041f274a1ff7c0ab47db7e8400 (diff) |
Fix issue #39
Diffstat (limited to 'lib')
-rw-r--r-- | lib/controller/collectionscontroller.php | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/controller/collectionscontroller.php b/lib/controller/collectionscontroller.php index 86476156..9eeb0608 100644 --- a/lib/controller/collectionscontroller.php +++ b/lib/controller/collectionscontroller.php @@ -61,12 +61,12 @@ class CollectionsController extends Controller { ); foreach ($collections as $key => $collection){ try{ - $tmp = (int)\OCP\Config::getUserValue($this->api->getUserId(), 'tasks_enhanced','show_'.$collection['id']); - if (!in_array($tmp, array(0,1,2)) || $tmp === null) { + $tmp = \OCP\Config::getUserValue($this->api->getUserId(), 'tasks_enhanced','show_'.$collection['id']); + if (!in_array((int)$tmp, array(0,1,2)) || $tmp === null) { $tmp = 2; \OCP\Config::setUserValue($this->api->getUserId(), 'tasks_enhanced','show_'.$collection['id'],$tmp); } - $collections[$key]['show'] = $tmp; + $collections[$key]['show'] = (int)$tmp; }catch(\Exception $e) { \OCP\Util::writeLog('tasks_enhanced', $e->getMessage(), \OCP\Util::ERROR); } |