From 04d9d9863d114e14cea54517c753faf7f7d169ca Mon Sep 17 00:00:00 2001 From: Michael Vogel Date: Sat, 11 Apr 2015 23:56:53 +0200 Subject: [PATCH] Fixed "Copy and paste" bug. --- include/acl_selectors.php | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/include/acl_selectors.php b/include/acl_selectors.php index 1e4343161..b2c4b31c8 100644 --- a/include/acl_selectors.php +++ b/include/acl_selectors.php @@ -181,12 +181,12 @@ function contact_select($selname, $selclass, $preselected = false, $size = 4, $p $sql_extra .= sprintf(" AND `rel` = %d ", intval(CONTACT_IS_FRIEND)); } - if($privmail) { - $sql_extra .= " AND `network` IN ( NETWORK_DFRN, NETWORK_DIASPORA ) "; - } - elseif($privatenet) { - $sql_extra .= " AND `network` IN ( NETWORK_DFRN, NETWORK_MAIL, NETWORK_FACEBOOK, NETWORK_DIASPORA ) "; - } + if($privmail) + $sql_extra .= sprintf(" AND `network` IN ('%s' , '%s') ", + NETWORK_DFRN, NETWORK_DIASPORA); + elseif($privatenet) + $sql_extra .= sprintf(" AND `network` IN ('%s' , '%s', '%s', '%s') ", + NETWORK_DFRN, NETWORK_MAIL, NETWORK_FACEBOOK, NETWORK_DIASPORA); $tabindex = ($tabindex > 0 ? "tabindex=\"$tabindex\"" : "");