当我在项目中安装纸卷和权限时运行命令时,每次都会发生此错误,但我没有从该错误中得到解决的线索
第54行错误
“ php”:“> = 7.0.0”, “ fideloper / proxy”:“〜3.3”, “ laravel / framework”:“ 5.5。*”, “ laravel / tinker”:“〜1.0”, “天才/角色”:“ ^ 3.0.2”
//这是整个文件,总行是54
命名空间App \ Exceptions;
使用异常; 使用Illuminate \ Foundation \ Exceptions \ Handler作为ExceptionHandler;
类处理程序扩展了ExceptionHandler { / ** *未报告的异常类型的列表。 * * @var数组 * / 受保护的$ dontReport = [ // ];
/**
* A list of the inputs that are never flashed for validation exceptions.
*
* @var array
*/
protected $dontFlash = [
'password',
'password_confirmation',
];
/**
* Report or log an exception.
*
* This is a great spot to send exceptions to Sentry, Bugsnag, etc.
*
* @param \Exception $exception
* @return void
*/
public function report(Exception $exception)
{
parent::report($exception);
}
/**
* Render an exception into an HTTP response.
*
* @param \Illuminate\Http\Request $request
* @param \Exception $exception
* @return \Illuminate\Http\Response
*/
public function render($request, Exception $exception)
{
return parent::render($request, $exception);
}
php artisan vendor:publish --provider =“ GeniusTS \ Roles \ RolesServiceProvider” --tag = config
//运行此命令后 //得到的错误是
PHP解析错误:语法错误,文件意外结束,第54行的C:\ xampp \ htdocs \ blog1 \ app \ Exceptions \ Handler.php中的预期函数(T_FUNCTION)或const(T_CONST)