You are here

public function DisqusException::__toString in Disqus 7

Converts the exception to a string.

File

./disqus.php, line 381
Provides the Disqus PHP API.

Class

DisqusException
Any unsucessful result that's created by Disqus API will generate a DisqusException.

Code

public function __toString() {
  $code = isset($this->disqus->code) ? $this->disqus->code : (isset($info['http_code']) ? $info['http_code'] : 0);
  $message = $this
    ->getMessage();
  return __CLASS__ . ": [{$code}]: {$message}\n";
}