[LON-CAPA-cvs] cvs: loncom /homework grades.pm

raeburn raeburn@source.lon-capa.org
Wed, 24 Dec 2008 07:04:58 -0000


raeburn		Wed Dec 24 07:04:58 2008 EDT

  Modified files:              
    /loncom/homework	grades.pm 
  Log:
  - Remove some duplicate code -- copies already exist 
    inside if ($env{'form.verifyrecord'}) {} block.
  - Restore Apache::loncommon::connection_aborted() call 
    after loop over @resources (removed in 1.542).   
  
  
Index: loncom/homework/grades.pm
diff -u loncom/homework/grades.pm:1.542 loncom/homework/grades.pm:1.543
--- loncom/homework/grades.pm:1.542	Wed Dec 24 06:31:41 2008
+++ loncom/homework/grades.pm	Wed Dec 24 07:04:58 2008
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # The LON-CAPA Grading handler
 #
-# $Id: grades.pm,v 1.542 2008/12/24 06:31:41 raeburn Exp $
+# $Id: grades.pm,v 1.543 2008/12/24 07:04:58 raeburn Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -7506,12 +7506,6 @@
         }
 
 	$completedstudents{$uname}={'line'=>$line};
-        my $lastpos = $env{'form.scantron_maxbubble'}*$scantron_config{'Qlength'};
-        my $studentdata = substr($line,$scantron_config{'Qstart'}-1,$lastpos);
-        chomp($studentdata);
-        $studentdata =~ s/\r$//;
-        my $studentrecord = '';
-        my $counter = -1;
         if ($env{'form.verifyrecord'}) {
             my $lastpos = $env{'form.scantron_maxbubble'}*$scantron_config{'Qlength'};
             my $studentdata = substr($line,$scantron_config{'Qstart'}-1,$lastpos);
@@ -7566,6 +7560,7 @@
                 }
             }
         }
+        if (&Apache::loncommon::connection_aborted($r)) { last; }
     } continue {
 	&Apache::lonxml::clear_problem_counter();
 	&Apache::lonnet::delenv('scantron\.');