From 8a7e844397694811b2f2d9c938b0ed5adf467313 Mon Sep 17 00:00:00 2001 From: Jeremy Kauffman Date: Tue, 5 Feb 2019 17:06:06 -0500 Subject: [PATCH] 17th time is the charm --- controller/Controller.class.php | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/controller/Controller.class.php b/controller/Controller.class.php index 20a03e8e..9a4d1717 100644 --- a/controller/Controller.class.php +++ b/controller/Controller.class.php @@ -82,15 +82,16 @@ class Controller */ $hostName = $_SERVER['HTTP_HOST']; if ($hostName && in_array($hostName, ['lbry.org', 'lbry.tv'])) { - if ($uri !== '/' && substr($uri, 0, 5) !== '/list') { //especially this line + if ($uri === '/') { + switch ($hostName) { + case 'lbry.org': + return ContentActions::executeOrg(); + case 'lbry.tv': + return ContentActions::executeTv(); + } + } elseif (substr($uri, 0, 5) !== '/list') { //especially this line return static::redirect('/'); } - switch ($hostName) { - case 'lbry.org': - return ContentActions::executeOrg(); - case 'lbry.tv': - return ContentActions::executeTv(); - } } }