Throw errors instead of abort()

This commit is contained in:
James Cole
2016-02-17 15:52:46 +01:00
parent 317aa591c3
commit 1a110de597
7 changed files with 55 additions and 38 deletions

View File

@@ -3,6 +3,7 @@
use Amount;
use Carbon\Carbon;
use Config;
use FireflyIII\Exceptions\FireflyException;
use FireflyIII\Helpers\Report\ReportQueryInterface;
use FireflyIII\Repositories\Account\AccountRepositoryInterface as ARI;
use FireflyIII\Repositories\Bill\BillRepositoryInterface;
@@ -247,7 +248,7 @@ class JsonController extends Controller
{
$pref = Preferences::get('tour', true);
if (!$pref) {
abort(404);
throw new FireflyException('Cannot find preference for tour. Exit.');
}
$headers = ['main-content', 'sidebar-toggle', 'account-menu', 'budget-menu', 'report-menu', 'transaction-menu', 'option-menu', 'main-content-end'];
$steps = [];