Bug 744691: Throw an error early when calling a method from a non-existent class

r=dkl, a=LpSolit


git-svn-id: svn://10.0.0.236/trunk@263851 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
mkanat%bugzilla.org 2012-05-24 06:30:44 +00:00
parent edd7726a92
commit acc01eb4d3
2 changed files with 2 additions and 1 deletions

View File

@ -1 +1 @@
8235
8236

View File

@ -15,6 +15,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)