mirror of
https://github.com/flarum/core.git
synced 2025-08-05 07:57:46 +02:00
Get rid of docblocks that don't add information
This commit is contained in:
@@ -20,9 +20,6 @@ use Illuminate\Contracts\Events\Dispatcher;
|
|||||||
|
|
||||||
class DiscussionMetadataUpdater
|
class DiscussionMetadataUpdater
|
||||||
{
|
{
|
||||||
/**
|
|
||||||
* @param Dispatcher $events
|
|
||||||
*/
|
|
||||||
public function subscribe(Dispatcher $events)
|
public function subscribe(Dispatcher $events)
|
||||||
{
|
{
|
||||||
$events->listen(Posted::class, [$this, 'whenPostWasPosted']);
|
$events->listen(Posted::class, [$this, 'whenPostWasPosted']);
|
||||||
@@ -31,9 +28,6 @@ class DiscussionMetadataUpdater
|
|||||||
$events->listen(Restored::class, [$this, 'whenPostWasRestored']);
|
$events->listen(Restored::class, [$this, 'whenPostWasRestored']);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* @param Posted $event
|
|
||||||
*/
|
|
||||||
public function whenPostWasPosted(Posted $event)
|
public function whenPostWasPosted(Posted $event)
|
||||||
{
|
{
|
||||||
$discussion = $event->post->discussion;
|
$discussion = $event->post->discussion;
|
||||||
@@ -46,9 +40,6 @@ class DiscussionMetadataUpdater
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* @param \Flarum\Post\Event\Deleted $event
|
|
||||||
*/
|
|
||||||
public function whenPostWasDeleted(Deleted $event)
|
public function whenPostWasDeleted(Deleted $event)
|
||||||
{
|
{
|
||||||
$this->removePost($event->post);
|
$this->removePost($event->post);
|
||||||
@@ -60,17 +51,11 @@ class DiscussionMetadataUpdater
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* @param \Flarum\Post\Event\Hidden $event
|
|
||||||
*/
|
|
||||||
public function whenPostWasHidden(Hidden $event)
|
public function whenPostWasHidden(Hidden $event)
|
||||||
{
|
{
|
||||||
$this->removePost($event->post);
|
$this->removePost($event->post);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* @param Restored $event
|
|
||||||
*/
|
|
||||||
public function whenPostWasRestored(Restored $event)
|
public function whenPostWasRestored(Restored $event)
|
||||||
{
|
{
|
||||||
$discussion = $event->post->discussion;
|
$discussion = $event->post->discussion;
|
||||||
@@ -83,9 +68,6 @@ class DiscussionMetadataUpdater
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* @param Post $post
|
|
||||||
*/
|
|
||||||
protected function removePost(Post $post)
|
protected function removePost(Post $post)
|
||||||
{
|
{
|
||||||
$discussion = $post->discussion;
|
$discussion = $post->discussion;
|
||||||
|
@@ -24,25 +24,16 @@ class DiscussionRenamedLogger
|
|||||||
*/
|
*/
|
||||||
protected $notifications;
|
protected $notifications;
|
||||||
|
|
||||||
/**
|
|
||||||
* @param NotificationSyncer $notifications
|
|
||||||
*/
|
|
||||||
public function __construct(NotificationSyncer $notifications)
|
public function __construct(NotificationSyncer $notifications)
|
||||||
{
|
{
|
||||||
$this->notifications = $notifications;
|
$this->notifications = $notifications;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* @param Dispatcher $events
|
|
||||||
*/
|
|
||||||
public function subscribe(Dispatcher $events)
|
public function subscribe(Dispatcher $events)
|
||||||
{
|
{
|
||||||
$events->listen(Renamed::class, [$this, 'whenDiscussionWasRenamed']);
|
$events->listen(Renamed::class, [$this, 'whenDiscussionWasRenamed']);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* @param \Flarum\Discussion\Event\Renamed $event
|
|
||||||
*/
|
|
||||||
public function whenDiscussionWasRenamed(Renamed $event)
|
public function whenDiscussionWasRenamed(Renamed $event)
|
||||||
{
|
{
|
||||||
$post = DiscussionRenamedPost::reply(
|
$post = DiscussionRenamedPost::reply(
|
||||||
|
@@ -54,19 +54,12 @@ class ValidateCustomLess
|
|||||||
$this->container = $container;
|
$this->container = $container;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* @param Dispatcher $events
|
|
||||||
*/
|
|
||||||
public function subscribe(Dispatcher $events)
|
public function subscribe(Dispatcher $events)
|
||||||
{
|
{
|
||||||
$events->listen(Saving::class, [$this, 'whenSettingsSaving']);
|
$events->listen(Saving::class, [$this, 'whenSettingsSaving']);
|
||||||
$events->listen(Saved::class, [$this, 'whenSettingsSaved']);
|
$events->listen(Saved::class, [$this, 'whenSettingsSaved']);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* @param Saving $event
|
|
||||||
* @throws ValidationException
|
|
||||||
*/
|
|
||||||
public function whenSettingsSaving(Saving $event)
|
public function whenSettingsSaving(Saving $event)
|
||||||
{
|
{
|
||||||
if (! isset($event->settings['custom_less'])) {
|
if (! isset($event->settings['custom_less'])) {
|
||||||
@@ -106,9 +99,6 @@ class ValidateCustomLess
|
|||||||
$this->container->instance(SettingsRepositoryInterface::class, $settings);
|
$this->container->instance(SettingsRepositoryInterface::class, $settings);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* @param Saved $event
|
|
||||||
*/
|
|
||||||
public function whenSettingsSaved(Saved $event)
|
public function whenSettingsSaved(Saved $event)
|
||||||
{
|
{
|
||||||
if (! isset($event->settings['custom_less'])) {
|
if (! isset($event->settings['custom_less'])) {
|
||||||
|
@@ -42,12 +42,6 @@ class EmailConfirmationMailer
|
|||||||
*/
|
*/
|
||||||
protected $translator;
|
protected $translator;
|
||||||
|
|
||||||
/**
|
|
||||||
* @param \Flarum\Settings\SettingsRepositoryInterface $settings
|
|
||||||
* @param Mailer $mailer
|
|
||||||
* @param UrlGenerator $url
|
|
||||||
* @param Translator $translator
|
|
||||||
*/
|
|
||||||
public function __construct(SettingsRepositoryInterface $settings, Mailer $mailer, UrlGenerator $url, Translator $translator)
|
public function __construct(SettingsRepositoryInterface $settings, Mailer $mailer, UrlGenerator $url, Translator $translator)
|
||||||
{
|
{
|
||||||
$this->settings = $settings;
|
$this->settings = $settings;
|
||||||
@@ -65,9 +59,6 @@ class EmailConfirmationMailer
|
|||||||
$events->listen(EmailChangeRequested::class, [$this, 'whenUserEmailChangeWasRequested']);
|
$events->listen(EmailChangeRequested::class, [$this, 'whenUserEmailChangeWasRequested']);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* @param \Flarum\User\Event\Registered $event
|
|
||||||
*/
|
|
||||||
public function whenUserWasRegistered(Registered $event)
|
public function whenUserWasRegistered(Registered $event)
|
||||||
{
|
{
|
||||||
$user = $event->user;
|
$user = $event->user;
|
||||||
@@ -86,9 +77,6 @@ class EmailConfirmationMailer
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* @param \Flarum\User\Event\EmailChangeRequested $event
|
|
||||||
*/
|
|
||||||
public function whenUserEmailChangeWasRequested(EmailChangeRequested $event)
|
public function whenUserEmailChangeWasRequested(EmailChangeRequested $event)
|
||||||
{
|
{
|
||||||
$email = $event->email;
|
$email = $event->email;
|
||||||
|
Reference in New Issue
Block a user