29 lines
658 B
PHP
29 lines
658 B
PHP
<?php
|
|
|
|
namespace Slack\Listeners;
|
|
|
|
use Illuminate\Support\Facades\Log;
|
|
use Illuminate\Contracts\Queue\ShouldQueue;
|
|
|
|
use Slack\Event\PinRemoved;
|
|
|
|
class PinRemovedListener implements ShouldQueue
|
|
{
|
|
protected const LOGKEY = 'LPR';
|
|
|
|
public $queue = 'slack';
|
|
|
|
/**
|
|
* Handle the event.
|
|
*
|
|
* @param PinRemoved $event
|
|
* @return void
|
|
*/
|
|
public function handle(PinRemoved $event): void
|
|
{
|
|
// Do some magic with event data
|
|
Log::info(sprintf('%s:Pin Removed from message [%s] in [%s]',self::LOGKEY,$event->ts,$event->channel_id),['m'=>__METHOD__]);
|
|
|
|
Log::debug(sprintf('%s:Ignoring Pin Remove on [%s]',static::LOGKEY,$event->ts),['m'=>__METHOD__]);
|
|
}
|
|
} |