Fix. Need to use system_clock

This commit is contained in:
Isaac Connor 2022-01-01 17:53:45 -05:00
parent a66adb6dcd
commit fd489c2c8d
1 changed files with 6 additions and 1 deletions

View File

@ -544,7 +544,12 @@ public:
} }
bool hasViewers() { bool hasViewers() {
if (shared_data && shared_data->valid) { if (shared_data && shared_data->valid) {
TimePoint now = std::chrono::steady_clock::now(); SystemTimePoint now = std::chrono::system_clock::now();
Debug(1, "Last viewed %" PRId64 " seconds ago",
static_cast<int64>(std::chrono::duration_cast<Seconds>(now.time_since_epoch()).count())
-
shared_data->last_viewed_time
);
return ( return (
( (
static_cast<int64>(std::chrono::duration_cast<Seconds>(now.time_since_epoch()).count()) static_cast<int64>(std::chrono::duration_cast<Seconds>(now.time_since_epoch()).count())