Add event action storage. Closes #2344
This commit is contained in:
@@ -11,6 +11,7 @@
|
||||
|
||||
namespace CachetHQ\Cachet\Bus\Events\User;
|
||||
|
||||
use CachetHQ\Cachet\Bus\Events\ActionInterface;
|
||||
use CachetHQ\Cachet\Models\User;
|
||||
|
||||
/**
|
||||
@@ -18,7 +19,7 @@ use CachetHQ\Cachet\Models\User;
|
||||
*
|
||||
* @author James Brooks <james@alt-three.com>
|
||||
*/
|
||||
final class UserLoggedOutEvent implements UserEventInterface
|
||||
final class UserLoggedOutEvent implements ActionInterface, UserEventInterface
|
||||
{
|
||||
/**
|
||||
* The user that logged out.
|
||||
@@ -48,4 +49,17 @@ final class UserLoggedOutEvent implements UserEventInterface
|
||||
{
|
||||
return 'User logged out.';
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the event action.
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public function getAction()
|
||||
{
|
||||
return [
|
||||
'user' => $this->user,
|
||||
'description' => (string) $this,
|
||||
];
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user