• Resolved JohnC28

    (@johnc28)


    At Line 221 of class-groups-group.php you do an === (identical) comparison on the parent id passed in.

    wpdb->get_var is returning a string.

    Since the group_id is an int in the database, it seems wrong to fail when an int is passing in to the create.

    Can’t that test be == (equals) rather than ===?

    Of could could cast the values in the comparison to avoid type issues?

    https://www.ads-software.com/plugins/groups/

Viewing 1 replies (of 1 total)
  • Plugin Author itthinx

    (@itthinx)

    The comparison you refer is intended to assure the existence of the parent group identified by its parent ID. This is expected to be equal in type and value so there’s really nothing wrong with that strict comparison ??

Viewing 1 replies (of 1 total)
  • The topic ‘Comparison bug when creating a group’ is closed to new replies.