Skip to content

Commit

Permalink
debug errorlogging
Browse files Browse the repository at this point in the history
  • Loading branch information
tamw-wnet committed Jun 27, 2024
1 parent ef6519a commit 563dc2d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions classes/class-pbs-check-dma.php
Original file line number Diff line number Diff line change
Expand Up @@ -77,14 +77,14 @@ public function get_location_from_ip($client_ip) {
error_log("parse error");
return array('errors' => $response);
}
$zipcode = $override_zipcode ? $override_zipcode : $zipcode;
$zipcode = $override_zipcode ? $override_zipcode : false;
$state = '';
$county = '';
if (!$override_zipcode && (empty($item['$links']) || !is_array($item['$links']))) {
error_log("links error");
return array('errors' => $response);
}
if (isset($item['$links'])) {
if (is_array($item['$links'])) {
foreach ($item['$links'] as $link) {
if ($link['$relationship'] == "related") {
$state = !empty($link['$items'][0]['$links'][0]['state']) ? $link['$items'][0]['$links'][0]['state'] : '';
Expand Down

0 comments on commit 563dc2d

Please sign in to comment.