Move code to event handlers instead of registration routine.

This commit is contained in:
James Cole
2016-03-28 19:50:24 +02:00
parent 70c8a524cd
commit cc88d5962e
6 changed files with 168 additions and 29 deletions

View File

@@ -0,0 +1,39 @@
<?php
/**
* UserRegistration.php
* Copyright (C) 2016 Sander Dorigo
*
* This software may be modified and distributed under the terms
* of the MIT license. See the LICENSE file for details.
*/
namespace FireflyIII\Events;
use FireflyIII\User;
use Illuminate\Queue\SerializesModels;
/**
* Class UserRegistration
*
* @package FireflyIII\Events
*/
class UserRegistration extends Event
{
use SerializesModels;
public $ip;
public $user;
/**
* Create a new event instance.
*
* @param User $user
*
* @return void
*/
public function __construct(User $user, string $ip)
{
$this->user = $user;
$this->ip = $ip;
}
}