uawdijnntqw1x1x1
IP : 3.22.81.107
Hostname : ns1.eurodns.top
Kernel : Linux ns1.eurodns.top 4.18.0-553.5.1.lve.1.el7h.x86_64 #1 SMP Fri Jun 14 14:24:52 UTC 2024 x86_64
Disable Function : mail,sendmail,exec,passthru,shell_exec,system,popen,curl_multi_exec,show_source,eval,open_base
OS : Linux
PATH:
/
home
/
sudancam
/
public_html
/
..
/
.trash
/
js
/
..
/
system.2
/
library
/
squareup
/
exception.php
/
/
<?php namespace Squareup; class Exception extends \Exception { const ERR_CODE_ACCESS_TOKEN_REVOKED = 'ACCESS_TOKEN_REVOKED'; const ERR_CODE_ACCESS_TOKEN_EXPIRED = 'ACCESS_TOKEN_EXPIRED'; private $config; private $log; private $language; private $errors; private $isCurlError; private $overrideFields = array( 'billing_address.country', 'shipping_address.country', 'email_address', 'phone_number' ); public function __construct($registry, $errors, $is_curl_error = false) { $this->errors = $errors; $this->isCurlError = $is_curl_error; $this->config = $registry->get('config'); $this->log = $registry->get('log'); $this->language = $registry->get('language'); $message = $this->concatErrors(); if ($this->config->get('config_error_log')) { $this->log->write($message); } parent::__construct($message); } public function isCurlError() { return $this->isCurlError; } public function isAccessTokenRevoked() { return $this->errorCodeExists(self::ERR_CODE_ACCESS_TOKEN_REVOKED); } public function isAccessTokenExpired() { return $this->errorCodeExists(self::ERR_CODE_ACCESS_TOKEN_EXPIRED); } protected function errorCodeExists($code) { if (is_array($this->errors)) { foreach ($this->errors as $error) { if ($error['code'] == $code) { return true; } } } return false; } protected function overrideError($field) { return $this->language->get('squareup_override_error_' . $field); } protected function parseError($error) { if (!empty($error['field']) && in_array($error['field'], $this->overrideFields)) { return $this->overrideError($error['field']); } $message = $error['detail']; if (!empty($error['field'])) { $message .= sprintf($this->language->get('squareup_error_field'), $error['field']); } return $message; } protected function concatErrors() { $messages = array(); if (is_array($this->errors)) { foreach ($this->errors as $error) { $messages[] = $this->parseError($error); } } else { $messages[] = $this->errors; } return implode(' ', $messages); } }
/home/sudancam/public_html/../.trash/js/../system.2/library/squareup/exception.php