Skip to content

Commit

Permalink
cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
timoj committed Nov 15, 2017
1 parent fc440dc commit e112b40
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions includes/wcwuunder-create.php
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,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 @@ -148,12 +150,11 @@ public function generateBookingUrl()
preg_match("!\r\n(?:Location|URI): *(.*?) *\r\n!i", $header, $matches);
$url = $matches[1];

// var_dump($wuunderData);
//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 e112b40

Please sign in to comment.