Diff for /loncom/auth/lonroles.pm between versions 1.323 and 1.324

version 1.323, 2017/01/02 19:44:11 version 1.324, 2017/01/21 19:58:05
Line 311  sub handler { Line 311  sub handler {
             my $cnum = $3;              my $cnum = $3;
             my $sec = $4;              my $sec = $4;
             if ($custom_adhoc) {              if ($custom_adhoc) {
                 my ($possroles,$description) = &Apache::lonnet::get_my_adhocroles($cdom.'_'.$cnum);                  my ($possroles,$description) = &Apache::lonnet::get_my_adhocroles($cdom.'_'.$cnum,1);
                 if (ref($possroles) eq 'ARRAY') {                  if (ref($possroles) eq 'ARRAY') {
                     if (grep(/^\Q$rolename\E$/,@{$possroles})) {                       if (grep(/^\Q$rolename\E$/,@{$possroles})) { 
                         if (&Apache::lonnet::check_adhoc_privs($cdom,$cnum,$update,$refresh,$now,                          if (&Apache::lonnet::check_adhoc_privs($cdom,$cnum,$update,$refresh,$now,
Line 397  sub handler { Line 397  sub handler {
 # Is this an ad hoc custom role in a course/community?  # Is this an ad hoc custom role in a course/community?
                     if (my ($domain,$rolename,$coursenum,$sec) = ($envkey =~ m{^form\.cr/($match_domain)/\1\-domainconfig/(\w+)\./\1/($match_courseid)(?:/(\w+)|$)})) {                      if (my ($domain,$rolename,$coursenum,$sec) = ($envkey =~ m{^form\.cr/($match_domain)/\1\-domainconfig/(\w+)\./\1/($match_courseid)(?:/(\w+)|$)})) {
                         if ($dhroles{$domain}) {                          if ($dhroles{$domain}) {
                             my ($possroles,$description) = &Apache::lonnet::get_my_adhocroles($domain.'_'.$coursenum);                              my ($possroles,$description) = &Apache::lonnet::get_my_adhocroles($domain.'_'.$coursenum,1);
                             if (ref($possroles) eq 'ARRAY') {                              if (ref($possroles) eq 'ARRAY') {
                                 if (grep(/^\Q$rolename\E$/,@{$possroles})) {                                  if (grep(/^\Q$rolename\E$/,@{$possroles})) {
                                     if (&Apache::lonnet::check_adhoc_privs($domain,$coursenum,$update,$refresh,$now,                                      if (&Apache::lonnet::check_adhoc_privs($domain,$coursenum,$update,$refresh,$now,

Removed from v.1.323  
changed lines
  Added in v.1.324


FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>