Skip to content
Snippets Groups Projects
Commit 1a60aa12 authored by eosrei's avatar eosrei Committed by e2thex
Browse files

Issue #1046916 by eosrei: importing nodes with their original NID

parent 70b618e6
No related branches found
No related tags found
No related merge requests found
......@@ -71,6 +71,10 @@ class FeedsNodeProcessor extends FeedsProcessor {
* Save a node.
*/
public function entitySave($entity) {
// If nid is set and a node with that id doesn't exist, flag as new.
if (!empty($entity->nid) && !node_load($entity->nid)) {
$entity->is_new = TRUE;
}
node_save($entity);
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment