This commit is contained in:
antv
2026-07-15 22:23:49 +07:00
parent d16db9c73d
commit 7f059dce86
4 changed files with 26 additions and 18 deletions
+2 -3
View File
@@ -78,13 +78,12 @@ class UserController extends Controller
// Send ChatOps notification from backend to avoid CORS issues
$chatOpsUrl = config('constants.CHATOPS_API_URL');
$chatOpsToken = config('constants.CHATOPS_API_TOKEN');
$email = 'antv@runsystem.net';
if ($chatOpsUrl && $chatOpsToken) {
if ($chatOpsUrl && $chatOpsToken && $receiverUser) {
try {
\Illuminate\Support\Facades\Http::timeout(5)->post($chatOpsUrl, [
'message' => "💌 Bạn nhận được một Thank Card mới!\nNhanh chân đến khu vực nhận thư để nhận ngay nhé!",
'userEmail' => $email,
'userEmail' => $receiverUser->mail,
'token' => $chatOpsToken,
]);
} catch (\Exception $e) {