Skip to content
14 changes: 9 additions & 5 deletions .github/workflows/run-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,18 +15,22 @@ jobs:
runs-on: ${{ matrix.os }}

strategy:
fail-fast: true
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest]
php: [8.1, '8.2', '8.3', '8.4']
laravel: ['10.*', '12.*']
php: [8.1, 8.2, 8.3, 8.4]
laravel: ['10.*', '11.*', '12.*']
stability: [prefer-lowest, prefer-stable]
include:
- laravel: 10.*
testbench: 8.0
testbench: 8.*
- laravel: 11.*
testbench: 9.*
- laravel: 12.*
testbench: '10.0'
testbench: 10.*
exclude:
- laravel: 11.*
php: 8.1
- laravel: 12.*
php: 8.1

Expand Down
10 changes: 5 additions & 5 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,12 @@
"spatie/laravel-package-tools": "^1.4.3"
},
"require-dev": {
"nunomaduro/collision": "^6.0",
"orchestra/testbench": "^7.0|^10.0",
"pestphp/pest": "^1.21|^3.7",
"pestphp/pest-plugin-laravel": "^1.2|^3.1",
"nunomaduro/collision": "^6.0|^7.0|^8.0",
"orchestra/testbench": "^7.0|^8.0|^9.0|^10.0",
"pestphp/pest": "^1.21|^2.0|^3.7",
"pestphp/pest-plugin-laravel": "^1.2|^2.0|^3.1",
"spatie/laravel-ray": "^1.29",
"vimeo/psalm": "^4.20|^6.6"
"vimeo/psalm": "^4.20|^5.0|^6.6"
},
"autoload": {
"psr-4": {
Expand Down
15 changes: 15 additions & 0 deletions resources/lang/es_ES.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"A failed login to your account": "Inicio de sesión incorrecto en su cuenta",
"Account:": "Cuenta:",
"Browser:": "Navegador:",
"Hello!": "¡Hola!",
"If this was you, you can ignore this alert. If you suspect any suspicious activity on your account, please change your password.": "Si ha sido usted, puede ignorar esta alerta. Si sospecha de cualquier actividad extraña en su cuenta, por favor cambie su password.",
"IP Address:": "Dirección IP:",
"Location:": "Localización:",
"Regards,": "Reciba un cordial saludo,",
"There has been a failed login attempt to your :app account.": "Se ha producido un intento de inicio de sesión erróneo con su cuenta en :app.",
"Time:": "Hora:",
"Unknown City": "Ciudad Desconocida",
"Unknown State": "Provincia desconocida",
"Your :app account logged in from a new device.": "Su cuenta en :app ha iniciado sesión desde un nuevo dispositivo."
}
2 changes: 1 addition & 1 deletion resources/views/emails/failed.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
> **@lang('IP Address:')** {{ $ipAddress }}<br/>
> **@lang('Browser:')** {{ $browser }}<br/>
@if ($location && $location['default'] === false)
> **@lang('Location:')** {{ $location['city'] ?? __('Unknown City') }}, {{ $location['state'], __('Unknown State') }}
> **@lang('Location:')** {{ $location['city'] ?? __('Unknown City') }}, {{ $location['state'] ?? __('Unknown State') }}
@endif

@lang('If this was you, you can ignore this alert. If you suspect any suspicious activity on your account, please change your password.')
Expand Down
2 changes: 1 addition & 1 deletion resources/views/emails/new.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
> **@lang('IP Address:')** {{ $ipAddress }}<br/>
> **@lang('Browser:')** {{ $browser }}<br/>
@if ($location && $location['default'] === false)
> **@lang('Location:')** {{ $location['city'] ?? __('Unknown City') }}, {{ $location['state'], __('Unknown State') }}
> **@lang('Location:')** {{ $location['city'] ?? __('Unknown City') }}, {{ $location['state'] ?? __('Unknown State') }}
@endif

@lang('If this was you, you can ignore this alert. If you suspect any suspicious activity on your account, please change your password.')
Expand Down
2 changes: 1 addition & 1 deletion src/Listeners/FailedLoginListener.php
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ public function handle($event): void
'user_agent' => $this->request->userAgent(),
'login_at' => now(),
'login_successful' => false,
'location' => config('authentication-log.notifications.new-device.location') ? optional(geoip()->getLocation($ip))->toArray() : null,
'location' => config('authentication-log.notifications.failed-login.location') ? optional(geoip()->getLocation($ip))->toArray() : null,
]);

if (config('authentication-log.notifications.failed-login.enabled')) {
Expand Down
Loading