summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorByron Jones <bjones@mozilla.com>2012-05-24 08:17:50 +0200
committerByron Jones <bjones@mozilla.com>2012-05-24 08:17:50 +0200
commit2d2fc6373bf882d5ddb16e3136567647cf2ef3ae (patch)
treedb5d45fc8c54ba9b9a082f5119a89601bfdbafb2
parentfc9858fed697d00fb921dd86448dad0ef70552a6 (diff)
downloadbugzilla-2d2fc6373bf882d5ddb16e3136567647cf2ef3ae.tar.gz
bugzilla-2d2fc6373bf882d5ddb16e3136567647cf2ef3ae.tar.xz
Bug 744691: Throw an error early when calling a method from a non-existent class
r=dkl, a=LpSolit
-rw-r--r--Bugzilla/WebService/Server.pm1
1 files changed, 1 insertions, 0 deletions
diff --git a/Bugzilla/WebService/Server.pm b/Bugzilla/WebService/Server.pm
index 4e0315219..feb80e9d0 100644
--- a/Bugzilla/WebService/Server.pm
+++ b/Bugzilla/WebService/Server.pm
@@ -25,6 +25,7 @@ use Scalar::Util qw(blessed);
sub handle_login {
my ($self, $class, $method, $full_method) = @_;
+ ThrowCodeError('unknown_method', {method => $full_method}) if !$class;
eval "require $class";
ThrowCodeError('unknown_method', {method => $full_method}) if $@;
return if ($class->login_exempt($method)