Skip to content

Model Class To Array Does Not Use Get Magic Method Or Allowed Fields Property #427

Description

@SmolSoftBoi

Because the Model->classToArray() method use reflection, it does not get values use the __get() magic method and could produce incorrect data, also I believe if the Model->allowedFields property is set then it should attempt to get those properties from the class too.

If this is something that's agreed I can implement this and create a pull request.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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