summaryrefslogtreecommitdiff
path: root/plugins/kolab_activesync
diff options
context:
space:
mode:
authorAleksander Machniak <alec@alec.pl>2013-05-07 10:16:11 (GMT)
committerAleksander Machniak <alec@alec.pl>2013-05-07 10:16:11 (GMT)
commit27e57c73352e1966918cdfe567c32c5a4844be82 (patch)
treeea26ec5a72f4ca39494833105a8bbeb50ce7f4e4 /plugins/kolab_activesync
parent828b868d973748c2e45f284fb7cf15e33a59b02e (diff)
downloadroundcubemail-plugins-kolab-27e57c73352e1966918cdfe567c32c5a4844be82.tar.gz
Fix undefined or unused variable errors caught in static code analysis
Diffstat (limited to 'plugins/kolab_activesync')
-rw-r--r--plugins/kolab_activesync/kolab_activesync.php4
-rw-r--r--plugins/kolab_activesync/kolab_activesync_ui.php6
2 files changed, 4 insertions, 6 deletions
diff --git a/plugins/kolab_activesync/kolab_activesync.php b/plugins/kolab_activesync/kolab_activesync.php
index 19604af..78f36c8 100644
--- a/plugins/kolab_activesync/kolab_activesync.php
+++ b/plugins/kolab_activesync/kolab_activesync.php
@@ -82,9 +82,9 @@ class kolab_activesync extends rcube_plugin
if (!$err) {
// iterate over folders list and update metadata if necessary
// old subscriptions
- foreach ($this->folder_meta() as $folder => $meta) {
+ foreach (array_keys($this->folder_meta()) as $folder) {
$err |= !$this->folder_set($folder, $imei, intval($subscriptions[$folder]));
- unset($subsciptions[$folder]);
+ unset($subscriptions[$folder]);
}
// new subscription
foreach ($subscriptions as $folder => $flag) {
diff --git a/plugins/kolab_activesync/kolab_activesync_ui.php b/plugins/kolab_activesync/kolab_activesync_ui.php
index 6e796cc..b723668 100644
--- a/plugins/kolab_activesync/kolab_activesync_ui.php
+++ b/plugins/kolab_activesync/kolab_activesync_ui.php
@@ -179,6 +179,7 @@ class kolab_activesync_ui
}
}
+ $folder_id = 'rcmf' . html_identifier($folder);
$names[] = $origname;
$classes = array('mailbox');
@@ -187,9 +188,6 @@ class kolab_activesync_ui
$classes[] = $folder_class;
}
- $folder_id = 'rcmf' . html_identifier($folder);
- $padding = str_repeat('&nbsp;&nbsp;&nbsp;&nbsp;', $level);
-
$table->add_row();
$table->add('subscription', $checkbox_sync->show(
!empty($subscribed[$folder]) ? $folder : null,
@@ -201,7 +199,7 @@ class kolab_activesync_ui
array('value' => $folder, 'id' => $folder_id.'_alarm')));
}
- $table->add(join(' ', $classes), html::label($folder_id, $padding . $foldername));
+ $table->add(join(' ', $classes), html::label($folder_id, $foldername));
}
return $table->show();