diff --git a/services/ans/src/notification_preferences.cpp b/services/ans/src/notification_preferences.cpp index e0d04f5a847fd27d52ac9bf2dbdf2952d06d7c3d..8bfeb8bcb979dec15ea3e9f265f4e8fd3c70b74c 100644 --- a/services/ans/src/notification_preferences.cpp +++ b/services/ans/src/notification_preferences.cpp @@ -903,8 +903,6 @@ void NotificationPreferences::RemoveSettings(int32_t userId) } if (preferncesDB_ != nullptr) { - preferncesDB_->RemoveNotificationEnable(userId); - preferncesDB_->RemoveDoNotDisturbDate(userId); preferncesDB_->DropUserTable(userId); } } diff --git a/services/ans/src/notification_rdb_data_mgr.cpp b/services/ans/src/notification_rdb_data_mgr.cpp index 4f544d05921887917b0f6650d40659d020185d7d..902683c558b2a401c2306961327b35dbd4279a09 100644 --- a/services/ans/src/notification_rdb_data_mgr.cpp +++ b/services/ans/src/notification_rdb_data_mgr.cpp @@ -395,7 +395,7 @@ int32_t NotificationDataMgr::QueryDataBeginWithKey( int32_t ret = absSharedResultSet->GoToFirstRow(); if (ret != NativeRdb::E_OK) { - ANS_LOGW("GoToFirstRow failed from %{public}s table.It is empty!, key=%{public}s", + ANS_LOGD("GoToFirstRow failed from %{public}s table.It is empty!, key=%{public}s", tableName.c_str(), key.c_str()); return NativeRdb::E_EMPTY_VALUES_BUCKET; } @@ -457,7 +457,7 @@ int32_t NotificationDataMgr::QueryAllData( int32_t ret = absSharedResultSet->GoToFirstRow(); if (ret != NativeRdb::E_OK) { - ANS_LOGW("GoToFirstRow failed from %{public}s table. It is empty!", tableName.c_str()); + ANS_LOGD("GoToFirstRow failed from %{public}s table. It is empty!", tableName.c_str()); return NativeRdb::E_EMPTY_VALUES_BUCKET; } @@ -496,7 +496,7 @@ int32_t NotificationDataMgr::DropUserTable(const int32_t userId) if (rdbStore_ == nullptr) { return NativeRdb::E_ERROR; } - std::string dropTableSql = "DROP TABLE IF EXISTS" + tableName; + std::string dropTableSql = "DROP TABLE IF EXISTS " + tableName; ret = rdbStore_->ExecuteSql(dropTableSql); } if (ret == NativeRdb::E_OK) {