elife/api-problem

eLife Sciences RFC 7807处理器

1.2.0 2024-05-27 09:16 UTC

This package is auto-updated.

Last update: 2024-08-27 09:50:01 UTC


README

Build Status

此库为eLife Sciences应用程序提供RFC 7807处理器

依赖关系

安装

composer require elife/api-problem

设置

Silex

use eLife\ApiProblem\Silex\ApiProblemProvider;

$app->register(new ApiProblemProvider());

异常详细信息(例如堆栈跟踪)将根据 $app['debug'] 的值包含在内。这可以通过将 $app['api_problem.factory.include_exception_details'] 设置为 truefalse 来覆盖。

运行测试

vendor/bin/phpunit