Permalink
Browse files

Ensuring the javascript provider class is loaded before checking meth…

…od on it
  • Loading branch information...
1 parent de7921a commit fa99b58622882a1728f2d3d2e708ccc1293626a5 @lorenzo lorenzo committed Jan 7, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/Cake/View/Helper/PaginatorHelper.php
@@ -93,7 +93,7 @@ public function __construct(View $View, $settings = array()) {
$this->_ajaxHelperClass = $ajaxProvider;
App::uses($ajaxProvider . 'Helper', 'View/Helper');
$classname = $ajaxProvider . 'Helper';
- if (!method_exists($classname, 'link')) {
+ if (!class_exists($classname) || !method_exists($classname, 'link')) {
throw new CakeException(sprintf(
__d('cake_dev', '%s does not implement a link() method, it is incompatible with PaginatorHelper'), $classname
));

0 comments on commit fa99b58

Please sign in to comment.