From 41afe03031cfda835d5e5ebee51281dc0e58e66b Mon Sep 17 00:00:00 2001 From: Ahmad Anbar Date: Sun, 26 Nov 2017 20:41:27 +0200 Subject: Fix issue #4454 --- system/libraries/Pagination.php | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'system/libraries') diff --git a/system/libraries/Pagination.php b/system/libraries/Pagination.php index f26f8a4ed..1a96e575d 100644 --- a/system/libraries/Pagination.php +++ b/system/libraries/Pagination.php @@ -352,9 +352,8 @@ class CI_Pagination { * @return CI_Pagination */ public function initialize(array $params = array()) - { - isset($params['attributes']) OR $params['attributes'] = array(); - if (is_array($params['attributes'])) + { + if (isset($params['attributes']) && is_array($params['attributes'])) { $this->_parse_attributes($params['attributes']); unset($params['attributes']); -- cgit v1.2.3-24-g4f1b From f609918247083634dac6c94712acdee625dea527 Mon Sep 17 00:00:00 2001 From: Ahmad Anbar Date: Sun, 26 Nov 2017 20:50:42 +0200 Subject: remove spaces --- system/libraries/Pagination.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'system/libraries') diff --git a/system/libraries/Pagination.php b/system/libraries/Pagination.php index 1a96e575d..9a57ecbaf 100644 --- a/system/libraries/Pagination.php +++ b/system/libraries/Pagination.php @@ -352,7 +352,7 @@ class CI_Pagination { * @return CI_Pagination */ public function initialize(array $params = array()) - { + { if (isset($params['attributes']) && is_array($params['attributes'])) { $this->_parse_attributes($params['attributes']); -- cgit v1.2.3-24-g4f1b From 0055dca60260d36a334f29bd61047eb076d38613 Mon Sep 17 00:00:00 2001 From: Ahmad Anbar Date: Mon, 27 Nov 2017 19:23:38 +0200 Subject: Enable rel attribute by default #4000 --- system/libraries/Pagination.php | 2 ++ 1 file changed, 2 insertions(+) (limited to 'system/libraries') diff --git a/system/libraries/Pagination.php b/system/libraries/Pagination.php index 9a57ecbaf..ece4edac9 100644 --- a/system/libraries/Pagination.php +++ b/system/libraries/Pagination.php @@ -339,6 +339,8 @@ class CI_Pagination { } } + // Enable rel attribute by default + isset($params['attributes']) OR $params['attributes'] = array(); $this->initialize($params); log_message('info', 'Pagination Class Initialized'); } -- cgit v1.2.3-24-g4f1b