Adjustments to the previous commit
diff --git a/system/core/Config.php b/system/core/Config.php
index 14ade72..e7cbe56 100644
--- a/system/core/Config.php
+++ b/system/core/Config.php
@@ -184,7 +184,7 @@
*
* @param string $item Config item name
* @param string $index Index name
- * @return string|null The configuration item or NULL on failure
+ * @return string|null The configuration item or NULL if the item doesn't exist
*/
public function item($item, $index = '')
{
diff --git a/tests/codeigniter/core/Config_test.php b/tests/codeigniter/core/Config_test.php
index e3be8a3..72f47cd 100644
--- a/tests/codeigniter/core/Config_test.php
+++ b/tests/codeigniter/core/Config_test.php
@@ -24,18 +24,18 @@
$this->assertEquals($this->cfg['base_url'], $this->config->item('base_url'));
// Bad Config value
- $this->assertFalse($this->config->item('no_good_item'));
+ $this->assertNull($this->config->item('no_good_item'));
// Index
- $this->assertFalse($this->config->item('no_good_item', 'bad_index'));
- $this->assertFalse($this->config->item('no_good_item', 'default'));
+ $this->assertNull($this->config->item('no_good_item', 'bad_index'));
+ $this->assertNull($this->config->item('no_good_item', 'default'));
}
// --------------------------------------------------------------------
public function test_set_item()
{
- $this->assertFalse($this->config->item('not_yet_set'));
+ $this->assertNull($this->config->item('not_yet_set'));
$this->config->set_item('not_yet_set', 'is set');
$this->assertEquals('is set', $this->config->item('not_yet_set'));
diff --git a/user_guide_src/source/changelog.rst b/user_guide_src/source/changelog.rst
index 71f5305..77cd39d 100644
--- a/user_guide_src/source/changelog.rst
+++ b/user_guide_src/source/changelog.rst
@@ -408,7 +408,7 @@
- Changed ``site_url()`` method to accept an array as well.
- Removed internal method ``_assign_to_config()`` and moved its implementation to *CodeIgniter.php* instead.
- - ``item()`` now returns NULL instead of FALSE when the required config item doesn't exist.
+ - ``item()`` now returns NULL instead of FALSE when the required config item doesn't exist.
- :doc:`Security Library <libraries/security>` changes include: