Merge pull request #26308 from vandekul/master

Fix matching zones query for working with sqlite
This commit is contained in:
Christopher Allford 2020-05-11 19:58:17 -07:00 committed by GitHub
commit 8332410939
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -282,7 +282,7 @@ class WC_Shipping_Zone_Data_Store extends WC_Data_Store_WP implements WC_Shippin
"SELECT zones.zone_id FROM {$wpdb->prefix}woocommerce_shipping_zones as zones
LEFT OUTER JOIN {$wpdb->prefix}woocommerce_shipping_zone_locations as locations ON zones.zone_id = locations.zone_id AND location_type != 'postcode'
WHERE " . implode( ' ', $criteria ) // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared
. ' ORDER BY zone_order ASC, zone_id ASC LIMIT 1'
. ' ORDER BY zone_order ASC, zones.zone_id ASC LIMIT 1'
);
}