mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-10-12 15:35:15 +00:00
Auto commit for release 'branch-v6.2' on 2024-12-14
This commit is contained in:
@@ -31,7 +31,6 @@ use Illuminate\Bus\Queueable;
|
||||
use Illuminate\Notifications\Messages\MailMessage;
|
||||
use Illuminate\Notifications\Messages\SlackMessage;
|
||||
use Illuminate\Notifications\Notification;
|
||||
use Illuminate\Support\Facades\Log;
|
||||
use NotificationChannels\Pushover\PushoverMessage;
|
||||
use Ntfy\Message;
|
||||
|
||||
@@ -82,7 +81,8 @@ class DisabledMFANotification extends Notification
|
||||
public function toPushover(User $notifiable): PushoverMessage
|
||||
{
|
||||
return PushoverMessage::create((string) trans('email.disabled_mfa_slack', ['email' => $this->user->email]))
|
||||
->title((string) trans('email.disabled_mfa_subject'));
|
||||
->title((string) trans('email.disabled_mfa_subject'))
|
||||
;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@@ -40,7 +40,6 @@ class EnabledMFANotification extends Notification
|
||||
|
||||
private User $user;
|
||||
|
||||
|
||||
public function __construct(User $user)
|
||||
{
|
||||
$this->user = $user;
|
||||
@@ -82,7 +81,8 @@ class EnabledMFANotification extends Notification
|
||||
public function toPushover(User $notifiable): PushoverMessage
|
||||
{
|
||||
return PushoverMessage::create((string) trans('email.enabled_mfa_slack', ['email' => $this->user->email]))
|
||||
->title((string) trans('email.enabled_mfa_subject'));
|
||||
->title((string) trans('email.enabled_mfa_subject'))
|
||||
;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -95,7 +95,6 @@ class EnabledMFANotification extends Notification
|
||||
return new SlackMessage()->content($message);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @SuppressWarnings(PHPMD.UnusedFormalParameter)
|
||||
*/
|
||||
|
@@ -93,10 +93,10 @@ class MFABackupFewLeftNotification extends Notification
|
||||
public function toPushover(User $notifiable): PushoverMessage
|
||||
{
|
||||
return PushoverMessage::create((string) trans('email.mfa_few_backups_left_slack', ['email' => $this->user->email, 'count' => $this->count]))
|
||||
->title((string) trans('email.mfa_few_backups_left_subject'));
|
||||
->title((string) trans('email.mfa_few_backups_left_subject'))
|
||||
;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @SuppressWarnings(PHPMD.UnusedFormalParameter)
|
||||
*/
|
||||
|
@@ -40,7 +40,6 @@ class MFABackupNoLeftNotification extends Notification
|
||||
|
||||
private User $user;
|
||||
|
||||
|
||||
public function __construct(User $user)
|
||||
{
|
||||
$this->user = $user;
|
||||
@@ -92,10 +91,10 @@ class MFABackupNoLeftNotification extends Notification
|
||||
public function toPushover(User $notifiable): PushoverMessage
|
||||
{
|
||||
return PushoverMessage::create((string) trans('email.mfa_few_backups_left_slack', ['email' => $this->user->email]))
|
||||
->title((string) trans('email.mfa_no_backups_left_slack'));
|
||||
->title((string) trans('email.mfa_no_backups_left_slack'))
|
||||
;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @SuppressWarnings(PHPMD.UnusedFormalParameter)
|
||||
*/
|
||||
|
@@ -47,7 +47,6 @@ class MFAManyFailedAttemptsNotification extends Notification
|
||||
$this->count = $count;
|
||||
}
|
||||
|
||||
|
||||
public function toArray(User $notifiable)
|
||||
{
|
||||
return [
|
||||
@@ -91,10 +90,10 @@ class MFAManyFailedAttemptsNotification extends Notification
|
||||
public function toPushover(User $notifiable): PushoverMessage
|
||||
{
|
||||
return PushoverMessage::create((string) trans('email.mfa_many_failed_slack', ['email' => $this->user->email, 'count' => $this->count]))
|
||||
->title((string) trans('email.mfa_many_failed_subject'));
|
||||
->title((string) trans('email.mfa_many_failed_subject'))
|
||||
;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @SuppressWarnings(PHPMD.UnusedFormalParameter)
|
||||
*/
|
||||
|
@@ -40,7 +40,6 @@ class MFAUsedBackupCodeNotification extends Notification
|
||||
|
||||
private User $user;
|
||||
|
||||
|
||||
public function __construct(User $user)
|
||||
{
|
||||
$this->user = $user;
|
||||
@@ -92,7 +91,8 @@ class MFAUsedBackupCodeNotification extends Notification
|
||||
public function toPushover(User $notifiable): PushoverMessage
|
||||
{
|
||||
return PushoverMessage::create((string) trans('email.used_backup_code_slack', ['email' => $this->user->email]))
|
||||
->title((string) trans('email.used_backup_code_subject'));
|
||||
->title((string) trans('email.used_backup_code_subject'))
|
||||
;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@@ -40,7 +40,6 @@ class NewBackupCodesNotification extends Notification
|
||||
|
||||
private User $user;
|
||||
|
||||
|
||||
public function __construct(User $user)
|
||||
{
|
||||
$this->user = $user;
|
||||
@@ -92,7 +91,8 @@ class NewBackupCodesNotification extends Notification
|
||||
public function toPushover(User $notifiable): PushoverMessage
|
||||
{
|
||||
return PushoverMessage::create((string) trans('email.new_backup_codes_slack', ['email' => $this->user->email]))
|
||||
->title((string) trans('email.new_backup_codes_subject'));
|
||||
->title((string) trans('email.new_backup_codes_subject'))
|
||||
;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@@ -1,4 +1,5 @@
|
||||
<?php
|
||||
|
||||
/*
|
||||
* UserFailedLoginAttempt.php
|
||||
* Copyright (c) 2024 james@firefly-iii.org.
|
||||
@@ -39,13 +40,11 @@ class UserFailedLoginAttempt extends Notification
|
||||
|
||||
private User $user;
|
||||
|
||||
|
||||
public function __construct(User $user)
|
||||
{
|
||||
$this->user = $user;
|
||||
}
|
||||
|
||||
|
||||
public function toArray(User $notifiable)
|
||||
{
|
||||
return [
|
||||
@@ -89,7 +88,8 @@ class UserFailedLoginAttempt extends Notification
|
||||
public function toPushover(User $notifiable): PushoverMessage
|
||||
{
|
||||
return PushoverMessage::create((string) trans('email.failed_login_message', ['email' => $this->user->email]))
|
||||
->title((string) trans('email.failed_login_subject'));
|
||||
->title((string) trans('email.failed_login_subject'))
|
||||
;
|
||||
}
|
||||
|
||||
/**
|
||||
|
Reference in New Issue
Block a user