where('tracking_token', $token)->first(); if ($log) { $log->forceFill([ 'first_opened_at' => $log->first_opened_at ?? now(), 'last_opened_at' => now(), 'opened_count' => ((int) $log->opened_count) + 1, ])->save(); } return response(base64_decode('R0lGODlhAQABAPAAAP///wAAACH5BAAAAAAALAAAAAABAAEAAAICRAEAOw=='), 200, [ 'Content-Type' => 'image/gif', 'Cache-Control' => 'no-store, no-cache, must-revalidate, max-age=0', ]); } }