ranjith-dev #164

Merged
jothi merged 2 commits from ranjith-dev into master 2026-01-31 12:35:24 +00:00
Showing only changes of commit 4a796a670a - Show all commits

View File

@@ -58,30 +58,30 @@ use App\Http\Livewire\CustomLogin;
'keys.auth' => 'required|string', 'keys.auth' => 'required|string',
]); ]);
// WebPushSubscription::updateOrCreate(
// ['endpoint' => $request->endpoint],
// [
// 'subscribable_type' => get_class($user),
// 'subscribable_id' => $user->id,
// 'public_key' => $request->keys['p256dh'],
// 'auth_token' => $request->keys['auth'],
// 'content_encoding' => $request->contentEncoding ?? 'aesgcm',
// ]
// );
WebPushSubscription::updateOrCreate( WebPushSubscription::updateOrCreate(
['endpoint' => $request->endpoint],
[ [
'endpoint' => $request->endpoint,
'subscribable_type' => get_class($user), 'subscribable_type' => get_class($user),
'subscribable_id' => $user->id, 'subscribable_id' => $user->id,
], 'public_key' => $request->keys['p256dh'],
[ 'auth_token' => $request->keys['auth'],
'public_key' => $request->keys['p256dh'], 'content_encoding' => $request->contentEncoding ?? 'aesgcm',
'auth_token' => $request->keys['auth'],
'content_encoding' => $request->contentEncoding ?? 'aesgcm',
] ]
); );
// WebPushSubscription::updateOrCreate(
// [
// 'endpoint' => $request->endpoint,
// 'subscribable_type' => get_class($user),
// 'subscribable_id' => $user->id,
// ],
// [
// 'public_key' => $request->keys['p256dh'],
// 'auth_token' => $request->keys['auth'],
// 'content_encoding' => $request->contentEncoding ?? 'aesgcm',
// ]
// );
return response()->json(['success' => true]); return response()->json(['success' => true]);
}); });