Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Fixing errors generated by ajaxProvider class not being loaded when c…

…hecking for method implementation.
  • Loading branch information...
commit 4d7fc24850021d64f0906e84fbf30cbc091ad1db 1 parent a43356c
@markstory markstory authored
Showing with 5 additions and 2 deletions.
  1. +5 −2 cake/libs/view/helpers/paginator.php
View
7 cake/libs/view/helpers/paginator.php
@@ -88,10 +88,13 @@ function __construct($config = array()) {
$ajaxProvider = isset($config['ajax']) ? $config['ajax'] : 'Js';
$this->helpers[] = $ajaxProvider;
$this->_ajaxHelperClass = $ajaxProvider;
- if (!method_exists($ajaxProvider . 'Helper', 'link')) {
+
+ App::import('Helper', $ajaxProvider);
+ $classname = $ajaxProvider . 'Helper';
+ if (!method_exists($classname, 'link')) {
$message = sprintf(
__('%s does not implement a link() method, it is incompatible with PaginatorHelper', true),
- $ajaxProvider . 'Helper'
+ $classname
);
trigger_error($message, E_USER_WARNING);
}
Please sign in to comment.
Something went wrong with that request. Please try again.