[Bps-public-commit] rt-extension-notifyslack branch, craig, updated. 50389446709c49e16c14f7bbfdaef39b554e5bf7

Craig Kaiser craig at bestpractical.com
Thu Nov 8 17:27:28 EST 2018


The branch, craig has been updated
       via  50389446709c49e16c14f7bbfdaef39b554e5bf7 (commit)
      from  f421b80ca2a5ce7397c1828ce06c3e0d7605e7e7 (commit)

Summary of changes:
 lib/RT/Action/NotifySlack.pm | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

- Log -----------------------------------------------------------------
commit 50389446709c49e16c14f7bbfdaef39b554e5bf7
Author: Craig Kaiser <craig at kaiserengineering.io>
Date:   Thu Nov 8 22:27:17 2018 +0000

    Remove check on transaction type

diff --git a/lib/RT/Action/NotifySlack.pm b/lib/RT/Action/NotifySlack.pm
index 954ede5..306726f 100644
--- a/lib/RT/Action/NotifySlack.pm
+++ b/lib/RT/Action/NotifySlack.pm
@@ -38,16 +38,13 @@ sub Commit {
     my $ua = LWP::UserAgent->new;
     $ua->timeout(15);
 
-    # prevent infinite loop between RT and Slack
-    return 0 if $self->TransactionObj->Type eq 'SlackNotified';
-
     my $payload = $self->TemplateObj->MIMEObj->as_string;
 
     my $req = POST("$webhook_url", ['payload' => $payload]);
 
     my $resp = $ua->request($req);
 
-    RT::Logger->debug("Failed post to slack, status is:" . $resp->status_line) unless $resp->is_success;
+    RT::Logger->error("Failed post to slack, status is:" . $resp->status_line) unless $resp->is_success;
 
     return 1;
 }

-----------------------------------------------------------------------


More information about the Bps-public-commit mailing list