mirror of
https://gitee.com/hyperf/hyperf.git
synced 2024-12-02 11:48:08 +08:00
Merge pull request #737 from hooklife/patch-1
修正 SwitchManager isEnable 判断
This commit is contained in:
commit
828dabdfd5
@ -18,6 +18,7 @@
|
||||
- [#713](https://github.com/hyperf-cloud/hyperf/pull/713) Fixed `ignoreAnnotations` does not works when cache is used.
|
||||
- [#717](https://github.com/hyperf-cloud/hyperf/pull/717) Fixed the validator will be created repeatedly in `getValidatorInstance`.
|
||||
- [#724](https://github.com/hyperf-cloud/hyperf/pull/724) Fixed `db:seed` command without database selected.
|
||||
- [#737](https://github.com/hyperf-cloud/hyperf/pull/737) Fixed custom process does not enable for tracer.
|
||||
|
||||
# v1.1.1 - 2019-10-08
|
||||
|
||||
|
@ -13,7 +13,7 @@ declare(strict_types=1);
|
||||
namespace Hyperf\Tracer;
|
||||
|
||||
use Hyperf\Utils\Context;
|
||||
use Psr\Http\Message\ServerRequestInterface;
|
||||
use OpenTracing\Span;
|
||||
|
||||
class SwitchManager
|
||||
{
|
||||
@ -46,6 +46,6 @@ class SwitchManager
|
||||
return false;
|
||||
}
|
||||
|
||||
return $this->config[$identifier] && Context::get(ServerRequestInterface::class) instanceof ServerRequestInterface;
|
||||
return $this->config[$identifier] && Context::get('tracer.root') instanceof Span;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user