The architectural concept of drupal_write_record() is obsolete. It should no longer be used.
db_merge() is the direct replacement.
No big news, since db_merge() is the preferred way since D7 already.
| Comment | File | Size | Author |
|---|---|---|---|
| #5 | remove-dwr-2194885-5.patch | 14.45 KB | berdir |
Comments
Comment #1
nico.pinos commentedWhat about this implementation?
Wouldn't that be
db_insert()?Comment #2
tstoecklerSo all of the 3 remaining non-test usages in core of drupal_write_record() stem from menu links. Let's postpone this on #2084421: Phase 2 - Decouple book module schema from menu links, which will move menu links to ContentEntityDatabaseStorage, i.e. obsoleting MenuLinkStorage and EntityDatabaseStorage.
Comment #3
Crell commentedWas that the right issue? That issue has been fixed for months. :-)
Comment #4
nico.pinos commentedI think you meant this #2277979: Menu link storage does not implement SqlEntityStorageInterface
Comment #5
berdirYep, unused now outside of tests :)
Comment #6
tim.plunkettBeautiful.
Comment #7
chx commentedAnd there was much rejoicing.
Comment #8
Crell commented(yay...)
Comment #9
alexpottAs much as I'd love to commit this I think we need a change record for this.
Comment #10
berdirYeah, wanted to do that, just wasn't fast enough :)
https://www.drupal.org/node/2340291 good enough?
Comment #11
alexpottCommitted 3295e62 and pushed to 8.0.x. Thanks!