class UserNotificationsController extends Controller
{
/**
* @param int $id Notification ID
* @return IlluminateHttpResponse
*/
public function show($id)
{
$notification = auth()->user()->notifications()->where('id', $id)->first();
if ($notification) {
$notification->markAsRead();
return redirect($notification->data['link']);
}
}
}