Skip to content

Commit 69cb452

Browse files
committed
bugfix for hot reloading
1 parent 46176c3 commit 69cb452

File tree

1 file changed

+5
-8
lines changed

1 file changed

+5
-8
lines changed

CommandTrayHost/configure.cpp

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1048,6 +1048,7 @@ int configure_reader(std::string& out)
10481048
//check for config item
10491049
if (enable_hot_reload)
10501050
{
1051+
config_i_unchanged = true;
10511052
if (cnt > (*global_configs_pointer).size())
10521053
{
10531054
config_i_unchanged = false;
@@ -2069,6 +2070,10 @@ void start_all(HANDLE ghJob, bool force)
20692070
for (auto& i : (*global_configs_pointer))
20702071
{
20712072
cache_config_cursor++;
2073+
if (json_object_has_member(i, "running") && i["running"].get<bool>())
2074+
{
2075+
continue;
2076+
}
20722077
if (force)
20732078
{
20742079
bool ignore_all = false;
@@ -2081,17 +2086,9 @@ void start_all(HANDLE ghJob, bool force)
20812086
{
20822087
i["enabled"] = true;
20832088
}
2084-
if (json_object_has_member(i, "running") && i["running"].get<bool>())
2085-
{
2086-
continue;
2087-
}
20882089
}
20892090
else
20902091
{
2091-
if (json_object_has_member(i, "running") && i["running"].get<bool>())
2092-
{
2093-
continue;
2094-
}
20952092
if (json_object_has_member(i, "crontab_config") && i["crontab_config"]["enabled"])
20962093
{
20972094
LOGMESSAGE(L"i[crontab_config][enabled]\n");

0 commit comments

Comments
 (0)