MDL-36620 - Blog, RSS - Preventing Guests from viewing the RSS of site level blogs
Conflicts: blog/rsslib.php
This commit is contained in:
committed by
Dan Poltawski
parent
27b92b4a71
commit
a201a0ff4e
@@ -163,6 +163,13 @@ function blog_rss_get_feed($context, $args) {
|
||||
return '';
|
||||
}
|
||||
|
||||
if ($CFG->bloglevel == BLOG_SITE_LEVEL) {
|
||||
if (isguestuser()) {
|
||||
debugging(get_string('nopermissiontoshow','error'));
|
||||
return '';
|
||||
}
|
||||
}
|
||||
|
||||
$sitecontext = get_context_instance(CONTEXT_SYSTEM);
|
||||
if (!has_capability('moodle/blog:view', $sitecontext)) {
|
||||
return null;
|
||||
|
||||
Reference in New Issue
Block a user