From 40a698fd0f43caab26f0d9eb679178be0b24b79e Mon Sep 17 00:00:00 2001 From: Petr Bena Date: Thu, 18 Jun 2015 14:20:56 +0200 Subject: [PATCH] more verbose about errors for patrolling on wiki --- huggle/Localization/en.xml | 1 + huggle/mainwindow.cpp | 6 ++++++ 2 files changed, 7 insertions(+) diff --git a/huggle/Localization/en.xml b/huggle/Localization/en.xml index 36e04c5ef..640bbba3a 100644 --- a/huggle/Localization/en.xml +++ b/huggle/Localization/en.xml @@ -348,6 +348,7 @@ Protect Delete Load + Patrolling is not enabled on $1 Restore this revision Show user info Ignore diff --git a/huggle/mainwindow.cpp b/huggle/mainwindow.cpp index 6f1c7539e..5ed4e36cb 100644 --- a/huggle/mainwindow.cpp +++ b/huggle/mainwindow.cpp @@ -2946,5 +2946,11 @@ void Huggle::MainWindow::on_actionPatrol_triggered() if (!this->CheckEditableBrowserPage()) return; + if (!this->CurrentEdit->GetSite()->GetProjectConfig()->Patrolling) + { + Syslog::HuggleLogs->ErrorLog(_l("main-patrol-not-enabled", this->CurrentEdit->GetSite()->Name)); + return; + } + this->PatrolEdit(); }