Skip to content

Commit

Permalink
fix to ensure build passes
Browse files Browse the repository at this point in the history
  • Loading branch information
matt committed Jul 19, 2024
1 parent a435f03 commit d7f2bca
Showing 1 changed file with 15 additions and 15 deletions.
30 changes: 15 additions & 15 deletions Http/Controllers/UnSubController.php
Original file line number Diff line number Diff line change
Expand Up @@ -136,15 +136,15 @@ function ($x) {
$response = $client->request('GET', $url);
}

$code = $response->getStatusCode();
$code = $response->getStatusCode();


$body = $response->getBody();

$conversation->setMeta("List-Unsubscribe-Submitted", ["status" => $response->getStatusCode(), "reason" => $response->getReasonPhrase()]);

$auth_user = auth()->user();
error_log($auth_user);
error_log($auth_user);
$created_by_user_id = (gettype($auth_user) == "object") ? $auth_user->id : $auth_user ;
\App\Thread::create(
$conversation, Thread::TYPE_LINEITEM,
Expand All @@ -163,10 +163,10 @@ function ($x) {
]
);

if ($code>=200 && $code <=299) {
$conversation->changeStatus(Conversation::STATUS_CLOSED,$auth_user, false);
}
if ($code>=200 && $code <=299) {
$conversation->changeStatus(Conversation::STATUS_CLOSED, $auth_user, false);
}
} catch (ConnectException $e) {

$auth_user = auth()->user();
Expand All @@ -185,10 +185,10 @@ function ($x) {
'code' => 501,
'message' => "Sorry, something went wrong: " . $e->getMessage(),
'lineNumber' => $e->getLine(),
'trace'=>$e->getTraceAsString(),
'method' => ($unsubPost) ? 'POST' : "GET",
'url' => $url,
'opts' => $opts,
'trace'=>$e->getTraceAsString(),
'method' => ($unsubPost) ? 'POST' : "GET",
'url' => $url,
'opts' => $opts,
]
]
);
Expand All @@ -210,11 +210,11 @@ function ($x) {
'code' => 501,
'message' => "Sorry, something went wrong: " . $e->getMessage(),
'lineNumber' => $e->getLine(),
'trace'=>$e->getTraceAsString(),
'method' => ($unsubPost) ? 'POST' : "GET",
'user' => json_encode($auth_user),
'url' => $url,
'opts' => $opts,
'trace'=>$e->getTraceAsString(),
'method' => ($unsubPost) ? 'POST' : "GET",
'user' => json_encode($auth_user),
'url' => $url,
'opts' => $opts,
]
]
);
Expand Down

0 comments on commit d7f2bca

Please sign in to comment.