Skip to content

Commit

Permalink
Fix logging
Browse files Browse the repository at this point in the history
  • Loading branch information
iverok committed Mar 3, 2020
1 parent 6f3b2cb commit 36903d1
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Vipps.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -1087,7 +1087,7 @@ public function vipps_shipping_details_callback() {
$methods[$key]= $method;
}
$chosen = apply_filters('woo_vipps_default_shipping_method', $chosen, $shipping_methods, $order);
if (!isset($methods[$chosen])) {
if ($chosen && !isset($methods[$chosen])) {
$chosen = null; // Actually that isn't available
$this->log(__("Unavailable shipping method set as default in the Vipps Express Checkout shipping callback - check the 'woo_vipps_default_shipping_method' filter",'debug'));
}
Expand Down
3 changes: 3 additions & 0 deletions readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -193,6 +193,9 @@ From version 1.1.13 you can also modify the javascript using the new WP hooks li

== Changelog ==

= 2020.03.03 version 1.4.2 =
* Tiny change to avoid logging non-errors if no shipping method has been chosen at all

= 2020.02.25 version 1.4.1 =
* Bugfix: The template chooser mechanism caused WP_DEBUG to print out error messages if the option wasn't set.

Expand Down
2 changes: 1 addition & 1 deletion woo-vipps.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
Author URI: https://www.wp-hosting.no/
Text-domain: woo-vipps
Domain Path: /languages
Version: 1.4.1
Version: 1.4.2
Requires at least: 4.7
Tested up to: 5.3.2
Expand Down

0 comments on commit 36903d1

Please sign in to comment.