summaryrefslogtreecommitdiff
path: root/includes/functions/functions_db.php
diff options
context:
space:
mode:
authorfisharebest <fisharebest@gmail.com>2010-09-18 08:46:13 +0000
committerfisharebest <fisharebest@gmail.com>2010-09-18 08:46:13 +0000
commitbbeadee379e94b41031669182ed364b13d9e43c9 (patch)
treedc2f6d0bd570aa55aa9fa12a41d355d574767e60 /includes/functions/functions_db.php
parent710987ace98fdfa006a2ab365980f05e2aa5e013 (diff)
downloadwebtrees-bbeadee379e94b41031669182ed364b13d9e43c9.tar.gz
webtrees-bbeadee379e94b41031669182ed364b13d9e43c9.tar.bz2
webtrees-bbeadee379e94b41031669182ed364b13d9e43c9.zip
Fix: check access levels of user/gedcom blocks http://webtrees.net/forums/10-help-for-ver-10-latest-release/3344-module-administration
Diffstat (limited to 'includes/functions/functions_db.php')
-rw-r--r--includes/functions/functions_db.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/includes/functions/functions_db.php b/includes/functions/functions_db.php
index fa9dc8dc35..183e98b760 100644
--- a/includes/functions/functions_db.php
+++ b/includes/functions/functions_db.php
@@ -2379,7 +2379,7 @@ function get_user_blocks($user_id, $gedcom_id=WT_GED_ID) {
" JOIN `##module` USING (module_name)".
" JOIN `##module_privacy` USING (module_name)".
" WHERE user_id=? AND `##module_privacy`.gedcom_id=?".
- " AND status='enabled' AND access_level>?".
+ " AND status='enabled' AND access_level>=?".
" ORDER BY location, block_order"
)->execute(array($user_id, $gedcom_id, WT_USER_ACCESS_LEVEL))->fetchAll();
foreach ($rows as $row) {
@@ -2417,7 +2417,7 @@ function get_gedcom_blocks($gedcom_id) {
" JOIN `##module` USING (module_name)".
" JOIN `##module_privacy` USING (module_name, gedcom_id)".
" WHERE gedcom_id=?".
- " AND status='enabled' AND access_level>?".
+ " AND status='enabled' AND access_level>=?".
" ORDER BY location, block_order"
)->execute(array($gedcom_id, WT_USER_ACCESS_LEVEL))->fetchAll();
foreach ($rows as $row) {