[LON-CAPA-cvs] cvs: loncom /interface londocs.pm

raeburn raeburn at source.lon-capa.org
Sat Sep 21 09:55:41 EDT 2013


raeburn		Sat Sep 21 13:55:41 2013 EDT

  Modified files:              
    /loncom/interface	londocs.pm 
  Log:
  - Eliminate duplicate declarations.
  - Actually assign a value to a new key in %pasteurls.
  
  
Index: loncom/interface/londocs.pm
diff -u loncom/interface/londocs.pm:1.563 loncom/interface/londocs.pm:1.564
--- loncom/interface/londocs.pm:1.563	Sun Sep  1 03:01:13 2013
+++ loncom/interface/londocs.pm	Sat Sep 21 13:55:41 2013
@@ -1,7 +1,7 @@
 # The LearningOnline Network
 # Documents
 #
-# $Id: londocs.pm,v 1.563 2013/09/01 03:01:13 raeburn Exp $
+# $Id: londocs.pm,v 1.564 2013/09/21 13:55:41 raeburn Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -712,7 +712,7 @@
              my $url = $env{'docs.markedcopy_url_'.$suffix};
              if (($cid =~ /^$match_domain(?:_)$match_courseid$/) &&
                  ($url ne '')) {
-                 $pasteurls{$cid.'_'.$url};
+                 $pasteurls{$cid.'_'.$url} = 1;
              }
         }
     }
@@ -1109,8 +1109,7 @@
     }
 
     my (%msgs,%before,%after, at dopaste,%is_map,%notinsupp,%notincrs,%duplicate,
-        %prefixchg,%srcdom,%srcnum,%marktomove,$save_err,$lockerrors,$allresult,
-        %msgs);
+        %prefixchg,%srcdom,%srcnum,%marktomove,$save_err,$lockerrors,$allresult);
 
     foreach my $suffix (@topaste) {
         my $url=&LONCAPA::map::qtescape($env{'docs.markedcopy_url_'.$suffix});
@@ -1561,7 +1560,7 @@
 sub dbcopy {
     my ($dbref,$coursedom,$coursenum,$lockerrorsref) = @_;
     my ($url,$result,$errtext);
-    my $url = $dbref->{'src'};
+    $url = $dbref->{'src'};
     if (ref($dbref) eq 'HASH') {
         if ($url =~ m{/(smppg|bulletinboard)$}) {
             my $prefix = $1;
@@ -3294,7 +3293,7 @@
                     push(@{$filtersref->{'randomorder'}},$orderidx);
                 }
             }
-            my $formname = 'edit_rorder_'.$orderidx;
+            $formname = 'edit_rorder_'.$orderidx;
 	    $rand_order_text = 
 '<form action="/adm/coursedocs" method="post" name="'.$formname.'">'."\n".
 $form_param."\n".




More information about the LON-CAPA-cvs mailing list