propelorm/Propel

Incorrect checking if primary key columns are all NULL in equals()

Opened this issue · 1 comments

When model is set to use multiple columns as its primary key it still has if (null === $this->getPrimaryKey() || null === $obj->getPrimaryKey()) condition in generated equals() method instead of using isPrimaryKeyNull method for this test. This leads to confirming, that two models are equal despite the fact they are not.

marcj commented

Care to send us a pull-request?