Skip to content

Commit

Permalink
Fix WiFi configuration changes not written fast enought to database
Browse files Browse the repository at this point in the history
  • Loading branch information
manup committed Aug 5, 2022
1 parent 042b6b5 commit 0e2f15e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions de_web_plugin_private.h
Original file line number Diff line number Diff line change
Expand Up @@ -465,6 +465,7 @@ using namespace deCONZ::literals;
#define DB_HUGE_SAVE_DELAY (60 * 60 * 1000) // 60 minutes
#define DB_LONG_SAVE_DELAY (15 * 60 * 1000) // 15 minutes
#define DB_SHORT_SAVE_DELAY (1 * 60 * 1000) // 1 minute
#define DB_FAST_SAVE_DELAY (1 * 1000) // 1 second

#define DB_CONNECTION_TTL (60 * 15) // 15 minutes

Expand Down
2 changes: 1 addition & 1 deletion rest_configuration.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2988,7 +2988,7 @@ int DeRestPluginPrivate::configureWifi(const ApiRequest &req, ApiResponse &rsp)
gwWifiLastUpdated = currentDateTime.toTime_t();

updateEtag(gwConfigEtag);
queSaveDb(DB_CONFIG | DB_SYNC, DB_SHORT_SAVE_DELAY);
queSaveDb(DB_CONFIG | DB_SYNC, DB_FAST_SAVE_DELAY);
}

QVariantMap rspItem;
Expand Down

0 comments on commit 0e2f15e

Please sign in to comment.