--- loncom/homework/chemresponse.pm 2011/07/04 09:24:54 1.89 +++ loncom/homework/chemresponse.pm 2011/11/14 03:08:01 1.90 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # chemical equation style response # -# $Id: chemresponse.pm,v 1.89 2011/07/04 09:24:54 foxr Exp $ +# $Id: chemresponse.pm,v 1.90 2011/11/14 03:08:01 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -337,8 +337,8 @@ sub end_organicresponse { if ($target eq 'grade' || $target eq 'web' || $target eq 'answer' || $target eq 'tex' || $target eq 'analyze') { - &Apache::lonxml::increment_counter(&Apache::response::repetition(), - "$partid.$id"); # part.response + my $repetition = &Apache::response::repetition(); + &Apache::lonxml::increment_counter($repetition,"$partid.$id"); # part.response if ($target eq 'analyze') { $Apache::lonhomework::analyze{"$partid.$id.type"} = 'organicresponse'; push (@{ $Apache::lonhomework::analyze{"parts"} },"$partid.$id"); @@ -599,7 +599,8 @@ sub end_reactionresponse { if ($target eq 'grade' || $target eq 'web' || $target eq 'answer' || $target eq 'tex' || $target eq 'analyze') { - &Apache::lonxml::increment_counter(&Apache::response::repetition(), "$partid.$id"); + my $repetition = &Apache::response::repetition(); + &Apache::lonxml::increment_counter($repetition,"$partid.$id"); if ($target eq 'analyze') { $Apache::lonhomework::analyze{"$partid.$id.type"} = 'reactionresponse'; push (@{ $Apache::lonhomework::analyze{"parts"} },"$partid.$id");