[LON-CAPA-cvs] cvs: loncom /lonnet/perl lonnet.pm

matthew lon-capa-cvs@mail.lon-capa.org
Tue, 10 Jun 2003 15:52:51 -0000


matthew		Tue Jun 10 11:52:51 2003 EDT

  Modified files:              
    /loncom/lonnet/perl	lonnet.pm 
  Log:
  Pass in usection on EXT calls.
  
  
Index: loncom/lonnet/perl/lonnet.pm
diff -u loncom/lonnet/perl/lonnet.pm:1.376 loncom/lonnet/perl/lonnet.pm:1.377
--- loncom/lonnet/perl/lonnet.pm:1.376	Wed May 21 15:57:46 2003
+++ loncom/lonnet/perl/lonnet.pm	Tue Jun 10 11:52:51 2003
@@ -1,7 +1,7 @@
 # The LearningOnline Network
 # TCP networking package
 #
-# $Id: lonnet.pm,v 1.376 2003/05/21 19:57:46 albertel Exp $
+# $Id: lonnet.pm,v 1.377 2003/06/10 15:52:51 matthew Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -3188,7 +3188,7 @@
 # --------------------------------------------------------- Value of a Variable
 
 sub EXT {
-    my ($varname,$symbparm,$udom,$uname,)=@_;
+    my ($varname,$symbparm,$udom,$uname,$usection)=@_;
 
     unless ($varname) { return ''; }
     #get real user name/domain, courseid and symb
@@ -3305,7 +3305,11 @@
 		($ENV{'user.domain'} eq $udom)) {
 		$section=$ENV{'request.course.sec'};
 	    } else {
-		$section=&usection($udom,$uname,$courseid);
+                if (! defined($usection)) {
+                    $section=&usection($udom,$uname,$courseid);
+                } else {
+                    $section = $usection;
+                }
 	    }
 
 	    my $seclevel=$courseid.'.['.$section.'].'.$spacequalifierrest;