[Koha-cvs] CVS: koha/C4 Context.pm,1.2,1.2.2.1

Andrew Arensburger arensb at users.sourceforge.net
Fri Oct 4 04:59:30 CEST 2002


Update of /cvsroot/koha/koha/C4
In directory usw-pr-cvs1:/tmp/cvs-serv29202

Modified Files:
      Tag: arensb-context
	Context.pm 
Log Message:
A couple of bug fixes so it'll actually load.


Index: Context.pm
===================================================================
RCS file: /cvsroot/koha/koha/C4/Context.pm,v
retrieving revision 1.2
retrieving revision 1.2.2.1
diff -C2 -r1.2 -r1.2.2.1
*** Context.pm	2 Oct 2002 17:21:09 -0000	1.2
--- Context.pm	4 Oct 2002 02:59:28 -0000	1.2.2.1
***************
*** 100,104 ****
  {
  	my $fname = shift;	# Config file to read
! 	my $retval;		# Return value: ref-to-hash holding the
  				# configuration
  
--- 100,104 ----
  {
  	my $fname = shift;	# Config file to read
! 	my $retval = {};	# Return value: ref-to-hash holding the
  				# configuration
  
***************
*** 142,146 ****
  	# Create a new context from the given config file name, if
  	# any, then set it as the current context.
! 	$context = __PACKAGE__->new($conf_fname);
  	$context->set_context;
  }
--- 142,147 ----
  	# Create a new context from the given config file name, if
  	# any, then set it as the current context.
! 	$context = new C4::Context($conf_fname);
! 	return undef if !defined($context);
  	$context->set_context;
  }
***************
*** 179,183 ****
  	# Load the desired config file.
  	$self->{"config"} = &read_config_file($conf_fname);
! 	return null if !defined($self->{"config"});
  
  	$self->{"dbh"} = undef;		# Database handle
--- 180,184 ----
  	# Load the desired config file.
  	$self->{"config"} = &read_config_file($conf_fname);
! 	return undef if !defined($self->{"config"});
  
  	$self->{"dbh"} = undef;		# Database handle





More information about the Koha-cvs mailing list