From 29e878a02a0f136758f9fb25a5f53da7f43cfef5 Mon Sep 17 00:00:00 2001 From: "Christian P. MOMON" Date: Fri, 3 May 2019 15:56:00 +0200 Subject: [PATCH] Restricted the use of the !stop command to the review owner (#3688). --- src/org/april/hebdobot/bot/hooks/StopReviewHook.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/org/april/hebdobot/bot/hooks/StopReviewHook.java b/src/org/april/hebdobot/bot/hooks/StopReviewHook.java index 0d2f451..31af89c 100644 --- a/src/org/april/hebdobot/bot/hooks/StopReviewHook.java +++ b/src/org/april/hebdobot/bot/hooks/StopReviewHook.java @@ -48,6 +48,10 @@ public class StopReviewHook extends Hook { bot.sendMessage(sender + ", pas de revue en cours, abandon impossible."); } + else if (!bot.getReview().isOwner(sender)) + { + bot.sendMessage(sender + ", vous n'êtes pas le conducteur de la réunion."); + } else { bot.sendMessage("Abandon de la revue en cours.");