mirror of
https://github.com/moodle/moodle.git
synced 2025-08-04 08:26:37 +02:00
bug #2420 fix
This commit is contained in:
parent
9c8febab60
commit
c0c6f36bf2
2 changed files with 3 additions and 2 deletions
|
@ -73,7 +73,7 @@ class block_rss_client extends block_base {
|
|||
|
||||
//if the user is an admin, course teacher, or all user are allowed -
|
||||
// then allow the user to add rss feeds
|
||||
if ( isadmin() || $submitters == SUBMITTERS_ALL_ACCOUNT_HOLDERS || ($submitters == SUBMITTERS_ADMIN_AND_TEACHER && $isteacher) ) {
|
||||
if ( !isguest() && (isadmin() || $submitters == SUBMITTERS_ALL_ACCOUNT_HOLDERS || ($submitters == SUBMITTERS_ADMIN_AND_TEACHER && $isteacher)) ) {
|
||||
$output .= '<div align="center"><a href="'. $CFG->wwwroot .'/blocks/rss_client/block_rss_client_action.php?courseid='. $courseid .'">'. get_string('block_rss_feeds_add_edit', 'block_rss_client') .'</a></div><br />';
|
||||
}
|
||||
|
||||
|
|
|
@ -46,9 +46,10 @@
|
|||
if ($courseid != 'none'){
|
||||
$isteacher = isteacher($courseid);
|
||||
}
|
||||
|
||||
//if the user is an admin or course teacher then allow the user to
|
||||
//assign categories to other uses than personal
|
||||
if (! ( isadmin() || $submitters == SUBMITTERS_ALL_ACCOUNT_HOLDERS || ($submitters == SUBMITTERS_ADMIN_AND_TEACHER && $isteacher) ) ) {
|
||||
if (isguest() || !( isadmin() || $submitters == SUBMITTERS_ALL_ACCOUNT_HOLDERS || ($submitters == SUBMITTERS_ADMIN_AND_TEACHER && $isteacher) ) ) {
|
||||
error(get_string('noguestpost', 'forum'), $referrer);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue