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

raeburn raeburn at source.lon-capa.org
Fri Mar 30 14:07:47 EDT 2018


raeburn		Fri Mar 30 18:07:47 2018 EDT

  Modified files:              
    /loncom/lonnet/perl	lonnet.pm 
  Log:
  - Stop retrieval of metadata for library file(s) -- rev. 1.1369 -- overwriting 
    %metaentry hash contents for resource containing them.
  
  
Index: loncom/lonnet/perl/lonnet.pm
diff -u loncom/lonnet/perl/lonnet.pm:1.1369 loncom/lonnet/perl/lonnet.pm:1.1370
--- loncom/lonnet/perl/lonnet.pm:1.1369	Tue Mar 27 04:36:11 2018
+++ loncom/lonnet/perl/lonnet.pm	Fri Mar 30 18:07:47 2018
@@ -1,7 +1,7 @@
 # The LearningOnline Network
 # TCP networking package
 #
-# $Id: lonnet.pm,v 1.1369 2018/03/27 04:36:11 raeburn Exp $
+# $Id: lonnet.pm,v 1.1370 2018/03/30 18:07:47 raeburn Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -11928,6 +11928,7 @@
 # Check metadata for imported file to
 # see if it contained response items
 #
+                        my %currmetaentry = %metaentry;
                         my $libresponseorder = &metadata($location,'responseorder');
                         my $origfile;
                         if ($libresponseorder ne '') {
@@ -11947,6 +11948,10 @@
                                 }
                             }
                         }
+# Do not overwrite contents of %metaentry hash for resource itself with 
+# hash populated for imported library file
+                        %metaentry = %currmetaentry;
+                        undef(%currmetaentry);
                         if ($importmode eq 'problem') {
 # Import as problem/response
                            $unikey=&add_prefix_and_part($prefix,$token->[2]->{'part'});




More information about the LON-CAPA-cvs mailing list