aboutsummaryrefslogtreecommitdiffstats
path: root/include/contact_widgets.php
diff options
context:
space:
mode:
Diffstat (limited to 'include/contact_widgets.php')
-rw-r--r--include/contact_widgets.php7
1 files changed, 4 insertions, 3 deletions
diff --git a/include/contact_widgets.php b/include/contact_widgets.php
index 11b087ac5..1230e2b24 100644
--- a/include/contact_widgets.php
+++ b/include/contact_widgets.php
@@ -86,10 +86,11 @@ function fileas_widget($baseurl,$selected = '') {
intval(local_user()),
intval(TERM_FILE)
);
- if(count($r)) {
- foreach($r as $rr)
+ if(! $r)
+ return;
+
+ foreach($r as $rr)
$terms[] = array('name' => $rr['term'], 'selected' => (($selected == $rr['term']) ? 'selected' : ''));
- }
return replace_macros(get_markup_template('fileas_widget.tpl'),array(
'$title' => t('Saved Folders'),