facebook/phabricator — pull request #68 by svemir (2011-10-15 14:26:04+00:00)
Title: If id field is not there, do not attempt to key array on it

When LiskDAO object does not use phid as a primary key, getIDKey assumes the key to be 'id'. That causes a problem with records such as PhabricatorSearchDocumentRelationship that have no 'id' field at all (it has phid but it is not unique.) When 'id' field is not there at all, loadAllFromArray a non-existent array element as a key for all records in the final array, basically leaving only one there.