Skip to content

Commit

Permalink
Update last_check in file logger record
Browse files Browse the repository at this point in the history
  • Loading branch information
HBRamiAlia authored and nickva committed Feb 27, 2023
1 parent ac600d1 commit 4df37bc
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/couch_log/src/couch_log_writer_file.erl
Original file line number Diff line number Diff line change
Expand Up @@ -107,8 +107,11 @@ maybe_reopen(St) ->
} = St,
Now = os:timestamp(),
case timer:now_diff(Now, LastCheck) > ?CHECK_INTERVAL of
true -> reopen(St);
false -> {ok, St}
true ->
NewSt = St#st{last_check = Now},
reopen(NewSt);
false ->
{ok, St}
end.

reopen(St) ->
Expand Down

0 comments on commit 4df37bc

Please sign in to comment.