diff --git a/include/library/Cana.php b/include/library/Cana.php index 3f9ef1887..6f0cb8509 100755 --- a/include/library/Cana.php +++ b/include/library/Cana.php @@ -155,6 +155,7 @@ class Cana extends Cana_Model { } $cmd = c::config()->dirs->root.'cli/timeout.php'.$sleep.' -c='.str_replace("'",'"',escapeshellarg($encoded)); + if ($async) { exec('nohup '.$cmd.' > /dev/null 2>&1 &'); } else { diff --git a/include/library/Crunchbutton/App.php b/include/library/Crunchbutton/App.php index 017fe5405..7de41a76a 100755 --- a/include/library/Crunchbutton/App.php +++ b/include/library/Crunchbutton/App.php @@ -36,6 +36,9 @@ class Crunchbutton_App extends Cana_App { case 'crunchbutton.localhost': $env = 'local'; break; + default: + $env = 'local'; + break; } switch ($_SERVER['__HTTP_HOST']) {