mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-10-12 15:35:15 +00:00
New code for email address change in profile. See #857
This commit is contained in:
51
app/Events/UserChangedEmail.php
Normal file
51
app/Events/UserChangedEmail.php
Normal file
@@ -0,0 +1,51 @@
|
||||
<?php
|
||||
/**
|
||||
* UserChangedEmail.php
|
||||
* Copyright (c) 2017 thegrumpydictator@gmail.com
|
||||
* This software may be modified and distributed under the terms of the
|
||||
* Creative Commons Attribution-ShareAlike 4.0 International License.
|
||||
*
|
||||
* See the LICENSE file for details.
|
||||
*/
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace FireflyIII\Events;
|
||||
|
||||
use FireflyIII\User;
|
||||
use Illuminate\Queue\SerializesModels;
|
||||
|
||||
/**
|
||||
* Class UserChangedEmail
|
||||
*
|
||||
* @package FireflyIII\Events
|
||||
*/
|
||||
class UserChangedEmail extends Event
|
||||
{
|
||||
use SerializesModels;
|
||||
|
||||
/** @var string */
|
||||
public $ipAddress;
|
||||
/** @var string */
|
||||
public $newEmail;
|
||||
/** @var string */
|
||||
public $oldEmail;
|
||||
/** @var User */
|
||||
public $user;
|
||||
|
||||
/**
|
||||
* UserChangedEmail constructor.
|
||||
*
|
||||
* @param User $user
|
||||
* @param string $newEmail
|
||||
* @param string $oldEmail
|
||||
* @param string $ipAddress
|
||||
*/
|
||||
public function __construct(User $user, string $newEmail, string $oldEmail, string $ipAddress)
|
||||
{
|
||||
$this->user = $user;
|
||||
$this->ipAddress = $ipAddress;
|
||||
$this->oldEmail = $oldEmail;
|
||||
$this->newEmail = $newEmail;
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user