Skip to content

Handling duplicate entries with the same parent ID #43

@GaryJones

Description

@GaryJones

When the same hook is called twice within the same function, the check for an existing ID will come up as true, even though the meta (e.g. line-number) will likely be different for the second call as the first call. Equally, if functions with the same name are defined twice, perhaps in the global namespace (parent ID = 0) in different files that are not included within the same request, they too will have different meta data and should be different entries.

Perhaps a join to postmeta table on the existing ID check and also compare the file and / or line number would narrow it down?

If the same hook is being called twice on the same line in the same file, well, that's just stupid! (But technically plausible.)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions