summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/HttpClient.php3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/HttpClient.php b/src/HttpClient.php
index f262a9f1..bfc65dc8 100644
--- a/src/HttpClient.php
+++ b/src/HttpClient.php
@@ -41,7 +41,8 @@ class HttpClient
return null;
}
- if (empty($ctx = json_decode($ctx, true))) {
+ $ctx = json_decode($ctx, true);
+ if (is_null($ctx)) {
// invalid context
return null;
}