Skip to content

Commit

Permalink
undo changes to setting user details
Browse files Browse the repository at this point in the history
  • Loading branch information
izsi-salmon committed Aug 16, 2022
1 parent 7744eff commit ba604be
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions src/Raygun4php/RaygunClient.php
Original file line number Diff line number Diff line change
Expand Up @@ -190,15 +190,16 @@ public function SetUser(
$isAnonymous = null,
$uuid = null
) {
$this->firstName = $this->StoreOrRetrieveUserCookie('rgfirstname', $firstName);
$this->fullName = $this->StoreOrRetrieveUserCookie('rgfullname', $fullName);
$this->email = $this->StoreOrRetrieveUserCookie('rgemail', $email);
$this->uuid = $this->StoreOrRetrieveUserCookie('rguuidvalue', $uuid);

$isAnonymousCookie = $this->StoreOrRetrieveUserCookie('rgisanonymous', $isAnonymous ? 'true' : 'false');
$this->isAnonymous = ($isAnonymousCookie === 'true');

if ((is_string($user) || is_numeric($user)) && !$isAnonymous) {
$this->user = $user;
$this->firstName = $this->StoreOrRetrieveUserCookie('rgfirstname', $firstName);
$this->fullName = $this->StoreOrRetrieveUserCookie('rgfullname', $fullName);
$this->email = $this->StoreOrRetrieveUserCookie('rgemail', $email);
$this->uuid = $this->StoreOrRetrieveUserCookie('rguuidvalue', $uuid);

if (php_sapi_name() != 'cli' && !headers_sent()) {
$this->setCookie('rguserid', $user);
Expand Down

0 comments on commit ba604be

Please sign in to comment.