Skip to content

DeepComparer returns false when compares null with null #806

Closed
@forrest79

Description

@forrest79

Hi,

I found out, that this code returns false: var_dump(DeepComparer::isEqual(null, null));.

I used temporary fix in our repo:

        $isLeftScalar = is_scalar($left) || is_null($left);
        $isRightScalar = is_scalar($right) || is_null($right);

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