sentry-php
sentry-php copied to clipboard
Strings that happen to be a php function are reported as a callable
How do you use Sentry?
Sentry SaaS (sentry.io)
SDK version
4.7.0
Steps to reproduce
If a function calling argument is an array containing various strings, any strings that happen to be a php function will be reported as a callable.
For example this array: ['scope' => 'header', 'type' => 'file'] will be reported as:
{
scope: Callable void header [string header; bool [replace]; int [response_code]],
type: Callable file [string filename; int [flags]; mixed|null [context]]
}
because header() and file() happen to be functions.
My 2 cents is that is_callable() should not be called on strings, they can be reported simply as strings.
Expected result
{
scope: header,
type: file
}
Actual result
{
scope: Callable void header [string header; bool [replace]; int [response_code]],
type: Callable file [string filename; int [flags]; mixed|null [context]]
}