Skip to content

Commit

Permalink
fix: strip away duplicate order comments field (#91)
Browse files Browse the repository at this point in the history
  • Loading branch information
ssolders authored Nov 2, 2023
1 parent e4cb024 commit fc26d3f
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 2 deletions.
8 changes: 8 additions & 0 deletions CHANGELOG.MD
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
## 1.7.7

* Strip away when duplicate order notes field

## 1.7.6

* Version bump

## 1.7.5

* Version bump
Expand Down
4 changes: 4 additions & 0 deletions assets/js/ledyer-checkout-for-woocommerce.js
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,10 @@ jQuery(function ($) {
* Moves all non standard fields to the extra checkout fields.
*/
moveExtraCheckoutFields: function () {
if (document.querySelectorAll("#order_comments_field").length > 1) {
document.querySelector("#order_comments_field").remove();
}


// Move order comments.
$('.woocommerce-additional-fields').appendTo('#lco-extra-checkout-fields');
Expand Down
2 changes: 1 addition & 1 deletion classes/class-ledyer-main.php
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ class Ledyer_Checkout_For_WooCommerce {
*/
public $checkout;

const VERSION = '1.7.5';
const VERSION = '1.7.7';
const SLUG = 'ledyer-checkout-for-woocommerce';
const SETTINGS = 'ledyer_checkout_for_woocommerce_settings';

Expand Down
2 changes: 1 addition & 1 deletion readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,6 @@ Tested up to: 6.3
Requires PHP: 7.0
WC requires at least: 4.0.0
WC tested up to: 8.2.0
Stable tag: 1.7.5
Stable tag: 1.7.6
License: GPLv3 or later
License URI: http://www.gnu.org/licenses/gpl-3.0.html

0 comments on commit fc26d3f

Please sign in to comment.