Problem/Motivation

The entityExists method doesn't properly check null values when building the query conditions. You end up with "LIKE NULL" in the where clause when it should be "IS NULL"

Steps to reproduce

I found this because we have a process that exports existing menu content items and sometimes the description or other properties are actually NULL. I could exclude the null values in my exporter, but I think we can handle this gracefully.

Proposed resolution

Create a separate condition when null is found.

CommentFileSizeAuthor
#5 yaml_content-n3246490-5.patch823 bytesdamienmckenna
Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

andyg5000 created an issue. See original summary.

andyg5000’s picture

Status: Active » Needs review

damienmckenna’s picture

Should the condition() line after the new code be moved into an else{} block?

damienmckenna’s picture

StatusFileSize
new823 bytes

Something like this.

Status: Needs review » Needs work

The last submitted patch, 5: yaml_content-n3246490-5.patch, failed testing. View results