Log Message:
-----------
change "die" to "croak" in a couple of places to make error messages
more useful.
Modified Files:
--------------
webwork2/lib/WeBWorK:
URLPath.pm
Revision Data
-------------
Index: URLPath.pm
===================================================================
RCS file: /webwork/cvs/system/webwork2/lib/WeBWorK/URLPath.pm,v
retrieving revision 1.27
retrieving revision 1.28
diff -Llib/WeBWorK/URLPath.pm -Llib/WeBWorK/URLPath.pm -u -r1.27 -r1.28
--- lib/WeBWorK/URLPath.pm
+++ lib/WeBWorK/URLPath.pm
@@ -24,6 +24,7 @@
use strict;
use warnings;
+use Carp;
use WeBWorK::Debug;
{
@@ -586,7 +587,7 @@
my ($invocant, $path) = @_;
my ($type, %args) = getPathType($path);
- die "no type matches path $path" unless $type;
+ croak "no type matches path $path" unless $type;
return $invocant->new(
type => $type,
@@ -605,7 +606,7 @@
my ($invocant, $module, %args) = @_;
my $type = getModuleType($module, keys %args);
- die "no type matches module $module with args", map { " $_=>$args{$_}" } keys %args unless $type;
+ croak "no type matches module $module with args", map { " $_=>$args{$_}" } keys %args unless $type;
return $invocant->new(
type => $type,
|