summaryrefslogtreecommitdiffstats
path: root/system/core
diff options
context:
space:
mode:
authorPascal Kriete <pascal.kriete@ellislab.com>2010-11-10 23:09:21 +0100
committerPascal Kriete <pascal.kriete@ellislab.com>2010-11-10 23:09:21 +0100
commitebb6f4bf664747d3649d622b98abc78f2da397f7 (patch)
tree069c9fb00b4af187c91a5c8b7013dc1856f6d114 /system/core
parenta9619f226a1a70b13dfd5adb0e8a201473832cc1 (diff)
Some simple tweaking
Diffstat (limited to 'system/core')
-rw-r--r--system/core/CodeIgniter.php3
-rw-r--r--system/core/URI.php11
2 files changed, 5 insertions, 9 deletions
diff --git a/system/core/CodeIgniter.php b/system/core/CodeIgniter.php
index fc334f050..595e00f27 100644
--- a/system/core/CodeIgniter.php
+++ b/system/core/CodeIgniter.php
@@ -221,7 +221,7 @@
// If this include fails it means that the default controller in the Routes.php file is not resolving to something valid.
if ( ! file_exists(APPPATH.'controllers/'.$RTR->fetch_directory().$RTR->fetch_class().EXT))
{
- show_error('Unable to load your default controller. Please make sure the controller specified in your Routes.php file is valid.');
+ show_error('Unable to load your default controller. Please make sure the controller specified in your Routes.php file is valid.');
}
include(APPPATH.'controllers/'.$RTR->fetch_directory().$RTR->fetch_class().EXT);
@@ -242,7 +242,6 @@
$method = $RTR->fetch_method();
if ( ! class_exists($class)
- OR $method == 'controller'
OR strncmp($method, '_', 1) == 0
OR in_array(strtolower($method), array_map('strtolower', get_class_methods('CI_Controller')))
)
diff --git a/system/core/URI.php b/system/core/URI.php
index b36593bc0..5a5a37cc6 100644
--- a/system/core/URI.php
+++ b/system/core/URI.php
@@ -482,21 +482,18 @@ class CI_URI {
*/
function _slash_segment($n, $where = 'trailing', $which = 'segment')
{
+ $leading = '/';
+ $trailing = '/';
+
if ($where == 'trailing')
{
- $trailing = '/';
$leading = '';
}
elseif ($where == 'leading')
{
- $leading = '/';
$trailing = '';
}
- else
- {
- $leading = '/';
- $trailing = '/';
- }
+
return $leading.$this->$which($n).$trailing;
}