[LON-CAPA-cvs] cvs: rat / lonuserstate.pm

raeburn lon-capa-cvs@mail.lon-capa.org
Fri, 18 Mar 2005 21:55:49 -0000


raeburn		Fri Mar 18 16:55:49 2005 EDT

  Modified files:              
    /rat	lonuserstate.pm 
  Log:
  Replace Apache::File() with open() so lonuserstate can be called outside Apache.
  
  
Index: rat/lonuserstate.pm
diff -u rat/lonuserstate.pm:1.87 rat/lonuserstate.pm:1.88
--- rat/lonuserstate.pm:1.87	Tue Mar 15 14:25:30 2005
+++ rat/lonuserstate.pm	Fri Mar 18 16:55:49 2005
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # Construct and maintain state and binary representation of course for user
 #
-# $Id: lonuserstate.pm,v 1.87 2005/03/15 19:25:30 albertel Exp $
+# $Id: lonuserstate.pm,v 1.88 2005/03/18 21:55:49 raeburn Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -32,7 +32,6 @@
 # ------------------------------------------------- modules used by this module
 use strict;
 use Apache::Constants qw(:common :http);
-use Apache::File;
 use HTML::TokeParser;
 use Apache::lonnet();
 use Apache::loncommon();
@@ -589,7 +588,7 @@
 # ---------------------------------------------------- Store away initial state
 	{
 	    my $cfh;
-	    if ($cfh=Apache::File->new(">$fn.state")) {
+	    if (open($cfh,">$fn.state")) {
 		print $cfh join("\n",@cond);
 	    } else {
 		&Apache::lonnet::logthis("<font color=blue>WARNING: ".