From 095751363dd9d3576ca7b8cfd3b3efbe9ce09bba Mon Sep 17 00:00:00 2001 From: Adam Date: Sun, 16 Oct 2016 18:50:22 -0400 Subject: db_sql: don't update objects pending creation as it duplicates it --- modules/database/db_sql.cpp | 2 ++ 1 file changed, 2 insertions(+) (limited to 'modules/database/db_sql.cpp') diff --git a/modules/database/db_sql.cpp b/modules/database/db_sql.cpp index 15501bc5f..12fc8512f 100644 --- a/modules/database/db_sql.cpp +++ b/modules/database/db_sql.cpp @@ -210,6 +210,8 @@ class DBSQL : public Module, public Pipe { if (this->shutting_down || obj->IsTSCached()) return; + if (obj->id == 0) + return; /* object is pending creation */ obj->UpdateTS(); this->updated_items.insert(obj); this->Notify(); -- cgit