Skip to content

Deprecated error on isOauth1 function using php8.1 #280

@dlopez-akalam

Description

@dlopez-akalam

The \Mautic\Auth\OAuth::isOauth1() method is potentially being called before the _request_token_url attribute is initialized. As result, a NULL value is passed to the strlen() php function, causing a deprecation warning.

Deprecated function: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in Mautic\Auth\OAuth->isOauth1() (line 525 of /.../vendor/mautic/api-library/lib/Auth/OAuth.php).
Mautic\Auth\OAuth->isOauth1() (Line: 564)
Mautic\Auth\OAuth->prepareRequest('https://mautic.example.com/api/forms', Array, Array, 'GET', Array) (Line: 115)
Mautic\Auth\AbstractAuth->makeRequest('https://mautic.example.com/api/forms', Array, 'GET', Array) (Line: 259)
Mautic\Api\Api->makeRequest('forms', Array) (Line: 399)
Mautic\Api\Api->getList('', 0, 100, '', 'ASC', 1, 1) (Line: 234)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions