From 25595c514fe50f124eb302e54569ded0c9b69bf3 Mon Sep 17 00:00:00 2001 From: kruglov Date: Wed, 3 Jul 2013 11:50:44 +0400 Subject: [PATCH] getLastError fix --- IntaroCrmRestApi.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/IntaroCrmRestApi.php b/IntaroCrmRestApi.php index 5120f61..1fa0b48 100644 --- a/IntaroCrmRestApi.php +++ b/IntaroCrmRestApi.php @@ -50,7 +50,10 @@ class IntaroCrmRestApi public function getLastError() { - return $this->statusCode . ' ' . $this->lastError; + if (!is_null($this->lastError)) + return $this->statusCode . ' ' . $this->lastError; + else + return null; } public function getLastErrorMessage()