Merge remote-tracking branch 'tdesktop/dev' into dev

This commit is contained in:
Eric Kotato 2020-06-01 14:42:46 +03:00
commit 82b804df63
2 changed files with 9 additions and 1 deletions

View file

@ -66,6 +66,9 @@ jobs:
- name: First set up.
run: |
# Workaround for permanent problems with third-party repository keys
sudo rm -rf /etc/apt/sources.list.d/*
sudo apt-get update
sudo apt-get install gcc-8 g++-8 -y
sudo snap install --classic snapcraft

View file

@ -478,12 +478,17 @@ std::optional<crl::time> LastUserInputTime() {
QDBusError::NotSupported,
};
const auto notSupportedErrorsToLog = {
QDBusError::Disconnected,
QDBusError::AccessDenied,
};
if (reply.isValid()) {
return (crl::now() - static_cast<crl::time>(reply.value()));
} else if (ranges::contains(notSupportedErrors, reply.error().type())) {
NotSupported = true;
} else {
if (reply.error().type() == QDBusError::AccessDenied) {
if (ranges::contains(notSupportedErrorsToLog, reply.error().type())) {
NotSupported = true;
}