From 39f6095a31afd719387a8489f8368a1bc702a5de Mon Sep 17 00:00:00 2001 From: Marcin Haba Date: Wed, 25 Nov 2015 22:56:33 +0100 Subject: [PATCH] baculum: Fix expectation failed error during restore --- gui/baculum/protected/Class/API.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gui/baculum/protected/Class/API.php b/gui/baculum/protected/Class/API.php index f4528e88e0..47b59f3123 100644 --- a/gui/baculum/protected/Class/API.php +++ b/gui/baculum/protected/Class/API.php @@ -94,7 +94,7 @@ class API extends TModule { $ch = $this->getConnection(); curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'PUT'); - curl_setopt($ch, CURLOPT_HTTPHEADER, array($this->getAPIHeader(), 'Accept: application/json', 'X-HTTP-Method-Override: PUT', 'Content-Length: ' . strlen($data))); + curl_setopt($ch, CURLOPT_HTTPHEADER, array($this->getAPIHeader(), 'Accept: application/json', 'X-HTTP-Method-Override: PUT', 'Content-Length: ' . strlen($data), 'Expect:')); curl_setopt($ch, CURLOPT_POST, true); curl_setopt($ch, CURLOPT_POSTFIELDS, $data); $result = curl_exec($ch); @@ -108,7 +108,7 @@ class API extends TModule { $data = http_build_query(array('create' => $options)); $ch = $this->getConnection(); curl_setopt($ch, CURLOPT_URL, $url); - curl_setopt($ch, CURLOPT_HTTPHEADER, array($this->getAPIHeader(), 'Accept: application/json')); + curl_setopt($ch, CURLOPT_HTTPHEADER, array($this->getAPIHeader(), 'Accept: application/json', 'Expect:')); curl_setopt($ch, CURLOPT_POST, true); curl_setopt($ch, CURLOPT_POSTFIELDS, $data); $result = curl_exec($ch); -- 2.39.5