aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/Wallabag/CoreBundle/Event/Activity/Actions/Federation/UnfollowEvent.php
blob: bf9a35f816d842ebac4c108a6329bae723e21745 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
<?php

namespace Wallabag\CoreBundle\Event\Activity\Actions\Federation;

use Wallabag\FederationBundle\Entity\Account;

/**
 * This event is fired as soon as an account is being unfollowed
 */
class UnfollowEvent extends FederationEvent
{
    const NAME = 'federation.unfollow';

    protected $follower;

    public function __construct(Account $accountFollowed, Account $follower)
    {
        parent::__construct($accountFollowed);
        $this->follower = $follower;
    }

    /**
     * @return Account
     */
    public function getFollower()
    {
        return $this->follower;
    }

    /**
     * @param Account $follower
     * @return UnfollowEvent
     */
    public function setFollower(Account $follower)
    {
        $this->follower = $follower;
        return $this;
    }
}