Skip to content

Commit

Permalink
Merge pull request #3 from kabisa/cleanup
Browse files Browse the repository at this point in the history
cleanup
  • Loading branch information
timoj authored Dec 12, 2017
2 parents 8a7aaf6 + c9d97ad commit d2d048e
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions includes/wcwuunder-create.php
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,8 @@ private function buildWuunderData($orderId)
}
if (count($dimensions) !== 3) {
$dimensions = array($defLength, $defWidth, $defHeight);
} else {
$dimensions = array()
}

$value = intval($order->get_subtotal() * 100);
Expand Down Expand Up @@ -155,13 +157,10 @@ public function generateBookingUrl()
preg_match("!\r\n(?:Location|URI): *(.*?) *\r\n!i", $header, $matches);
$url = $matches[1];

// echo "<pre>";
// var_dump($wuunderData);
// Close connection
curl_close($cc);

update_post_meta($order_id, '_wuunder_label_booking_url', $url);
echo $url;
if (!(substr($url, 0, 5) === "http:" || substr($url, 0, 6) === "https:")) {
if ($status == 'productie') {
$url = 'https://api.wuunder.co' . $url;
Expand Down

0 comments on commit d2d048e

Please sign in to comment.