Cleaner regex

Signed-off-by: Aaron Kuzemchak <aaron@kuzemchak.net>
This commit is contained in:
Aaron Kuzemchak 2012-09-15 20:48:18 -04:00
parent 03acf9ca50
commit 581fcc5c47
1 changed files with 1 additions and 1 deletions

View File

@ -137,7 +137,7 @@
foreach ($languages as $language)
{
if (preg_match("#^{$language}(/.*)?$#i", $uri))
if (preg_match("#^{$language}(?:$|/)#i", $uri))
{
Config::set('application.language', $language);