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

albertel lon-capa-cvs@mail.lon-capa.org
Thu, 23 Dec 2004 17:08:22 -0000


albertel		Thu Dec 23 12:08:22 2004 EDT

  Modified files:              
    /loncom/homework	radiobuttonresponse.pm 
  Log:
  - fixes BUG#3748
  
  
Index: loncom/homework/radiobuttonresponse.pm
diff -u loncom/homework/radiobuttonresponse.pm:1.96 loncom/homework/radiobuttonresponse.pm:1.97
--- loncom/homework/radiobuttonresponse.pm:1.96	Wed Oct 20 23:34:06 2004
+++ loncom/homework/radiobuttonresponse.pm	Thu Dec 23 12:08:22 2004
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # mutliple choice style responses
 #
-# $Id: radiobuttonresponse.pm,v 1.96 2004/10/21 03:34:06 albertel Exp $
+# $Id: radiobuttonresponse.pm,v 1.97 2004/12/23 17:08:22 albertel Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -312,6 +312,9 @@
 		&Apache::lonxml::error(&HTML::Entities::encode("No valid value assigned ($Apache::response::foilgroup{$name.'.value'}) for foil $name in <foilgroup>",'<>&"'));
 	    }
 	}
+	if (!$havetrue && $Apache::lonhomework::type ne 'survey') {
+	    &Apache::lonxml::error("There are no true statements available.<br />");
+	}
     } else {
 	my $current=0;
 	&Apache::lonhomework::showhash(%Apache::response::foilgroup);