Skip to content

New task: Change usages of FakerPHP property accessors to method calls #47

Closed
@ordago

Description

@ordago

What would you like to do?

FakerPHP/Faker#164

In that pull request FakerPHP has marked property access as deprecated

    /**
     * @param string $attribute
     *
     * @deprecated Use a method instead.
     */
    public function __get($attribute)
    {
        trigger_deprecation('fakerphp/faker', '1.14', 'Accessing property "%s" is deprecated, use "%s()" instead.', $attribute, $attribute);


        return $this->format($attribute);
    }

Before/After code snippets

- $this->faker->lastName;
+ $this->faker->lastName();

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions