From 61098b11f2662a820780b97a11bd8621a50d7315 Mon Sep 17 00:00:00 2001 From: Boy132 Date: Sat, 19 Jul 2025 16:47:49 +0200 Subject: [PATCH] Add migration to clear password from `auth:fail` logs (#1533) --- ...1_clear_password_from_failed_auth_logs.php | 29 +++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 database/migrations/2025_07_19_141511_clear_password_from_failed_auth_logs.php diff --git a/database/migrations/2025_07_19_141511_clear_password_from_failed_auth_logs.php b/database/migrations/2025_07_19_141511_clear_password_from_failed_auth_logs.php new file mode 100644 index 000000000..8ff24c81c --- /dev/null +++ b/database/migrations/2025_07_19_141511_clear_password_from_failed_auth_logs.php @@ -0,0 +1,29 @@ +get(); + foreach ($logs as $log) { + $log->update(['properties' => collect($log->properties)->except(['password'])->toArray()]); + } + }); + } + + /** + * Reverse the migrations. + */ + public function down(): void + { + // Not needed + } +};