如何在控制器中使用Laravel Debugbar?

时间:2017-01-18 08:50:43

标签: laravel-5

尝试在控制器操作Class 'App\Http\Controllers\Debugbar' not found

中使用后,我收到错误Debugbar::error('Error!');

LARAVEL DEBUGBAR以这种方式安装:

在控制台composer require barryvdh/laravel-debugbar

在config / app.php中添加Barryvdh\Debugbar\ServiceProvider::class'Debugbar' => Barryvdh\Debugbar\Facade::class,

Laravel 5.3

Debugbar正在网站上工作 - 即使出现此错误,我也可以在底部看到它。但是如何修复这个关键错误信息?

1 个答案:

答案 0 :(得分:2)

明确使用Facade或从根名称空间使用Debugbar。

% delete A[:,:,4]
B = A(:,:,[1:3,5])
% permute dimension 2 and 3, because you want to concatenate your array according to the 3nd dimension before the 2nd dimension.
C = permute(B,[1 3 2])
% Use reshape with the first parameter beeing '[]' so matlab will automatically compute the number of line needed, the number of column is fixed: it's 2 or size(B,2)
C = reshape(C,[],size(B,2))