mirror of
https://github.com/flarum/core.git
synced 2025-07-25 18:51:40 +02:00
Make listener methods static
This is needed since we're listening to the individual methods of the class, as opposed to registering the class as a subscriber.
This commit is contained in:
@@ -20,7 +20,7 @@ class CreatePostWhenDiscussionIsStickied
|
||||
/**
|
||||
* @param DiscussionWasStickied $event
|
||||
*/
|
||||
public function whenDiscussionWasStickied(DiscussionWasStickied $event)
|
||||
public static function whenDiscussionWasStickied(DiscussionWasStickied $event)
|
||||
{
|
||||
static::stickyChanged($event->discussion, $event->user, true);
|
||||
}
|
||||
@@ -28,7 +28,7 @@ class CreatePostWhenDiscussionIsStickied
|
||||
/**
|
||||
* @param DiscussionWasUnstickied $event
|
||||
*/
|
||||
public function whenDiscussionWasUnstickied(DiscussionWasUnstickied $event)
|
||||
public static function whenDiscussionWasUnstickied(DiscussionWasUnstickied $event)
|
||||
{
|
||||
static::stickyChanged($event->discussion, $event->user, false);
|
||||
}
|
||||
|
Reference in New Issue
Block a user