summaryrefslogtreecommitdiffstats
path: root/lib/general.lib.php
diff options
context:
space:
mode:
authorKarl 'vollmerk' Vollmer <vollmer@ampache.org>2005-12-23 06:49:34 +0000
committerKarl 'vollmerk' Vollmer <vollmer@ampache.org>2005-12-23 06:49:34 +0000
commitc47908044458821b83ad1954dd3bc29248e2fc4b (patch)
treeb72f93cac1b8fffaa6a047e1f2ebea5ff5d2757a /lib/general.lib.php
parentcb14ac7b4bddc4f8ee59ef4b7d7e6ddb9cacbaaf (diff)
downloadampache-c47908044458821b83ad1954dd3bc29248e2fc4b.tar.gz
ampache-c47908044458821b83ad1954dd3bc29248e2fc4b.tar.bz2
ampache-c47908044458821b83ad1954dd3bc29248e2fc4b.zip
adding it_IT and fixing a bug that let guests use batch download
Diffstat (limited to 'lib/general.lib.php')
-rw-r--r--lib/general.lib.php8
1 files changed, 5 insertions, 3 deletions
diff --git a/lib/general.lib.php b/lib/general.lib.php
index 6e38bf0e..decd5fc1 100644
--- a/lib/general.lib.php
+++ b/lib/general.lib.php
@@ -468,13 +468,15 @@ function scrub_in($str) {
/*!
@function batch_ok()
@discussion return boolean if user can batch download
+ //FIXME: This needs to be fixed, it shouldn't be an independent function
+ //FIXME: It should reference a central one maybe the access object?
*/
function batch_ok( ) {
- global $user;
+
// i check this before showing any link
// should make it easy to tie to a new pref if you choose to add it
- if (conf('allow_zip_download')) {
- return( $user->prefs['download'] );
+ if (conf('allow_zip_download') AND $GLOBALS['user']->has_access(25)) {
+ return( $GLOBALS['user']->prefs['download'] );
} // if allowed zip downloads
return false;