Skip to content

Commit

Permalink
merged fix for MDL-6549, fix for wrong publish to menu
Browse files Browse the repository at this point in the history
  • Loading branch information
toyomoyo committed Oct 19, 2006
1 parent b7cec86 commit c345209
Showing 1 changed file with 11 additions and 3 deletions.
14 changes: 11 additions & 3 deletions blog/lib.php
Expand Up @@ -259,9 +259,17 @@ function blog_applicable_publish_states($courseid='') {
global $CFG;

// everyone gets draft access
$options = array ( 'draft' => get_string('publishtonoone', 'blog') );
$options['site'] = get_string('publishtosite', 'blog');
$options['public'] = get_string('publishtoworld', 'blog');
if ($CFG->bloglevel >= BLOG_USER_LEVEL) {
$options = array ( 'draft' => get_string('publishtonoone', 'blog') );
}

if ($CFG->bloglevel > BLOG_USER_LEVEL) {
$options['site'] = get_string('publishtosite', 'blog');
}

if ($CFG->bloglevel >= BLOG_GLOBAL_LEVEL) {
$options['public'] = get_string('publishtoworld', 'blog');
}

return $options;
}
Expand Down

0 comments on commit c345209

Please sign in to comment.