PluginProbe
PayPlug for WooCommerce (Official) / 3.1.0
PayPlug for WooCommerce (Official) v3.1.0
3.1.0 3.0.0 2.18.0 1.0.17 1.0.18 1.0.19 1.0.20 1.0.21 1.0.22 1.0.3 1.0.4 1.0.5 1.0.6 1.0.7 1.0.8 1.1.0 1.10.0 1.10.1 1.2.1 1.2.10 1.2.11 1.2.2 1.2.3 1.2.4 1.2.5 All 102 releases
← All changes | src/Service/Configuration.php +18 -1 2.18.0 → 3.1.0 View file →
@@ -482,8 +482,25 @@
482 482 'active' => [
483 483 'type' => 'bool',
484 484 'default' => false,
485 485 ],
486 + 'default_amounts' => [
487 + 'type' => 'string',
488 + // Last-resort fallback only, used when the account's live API bounds
489 + // (payment_methods.permissions.scalapay.amounts) aren't available yet.
490 + // Kept in sync with Scalapay::DEFAULT_MIN_AMOUNT/DEFAULT_MAX_AMOUNT,
491 + // which cover the case where this key itself is missing from a stored
492 + // options array. This schema is intentionally dependency-free, so the
493 + // values are repeated here as a literal rather than referenced.
494 + 'default' => '{"min":500, "max":400000}',
495 + ],
496 + 'custom_amounts' => [
497 + 'type' => 'string',
498 + // Empty means "not customized yet" - the merchant's actual choice, if
499 + // any. Must NOT default to a concrete value, or that value would be
500 + // read as an explicit override of the account's live API bounds.
501 + 'default' => '{}',
502 + ],
486 503 ],
487 504 ],
488 505 ],
489 506
@@ -584,9 +601,9 @@
584 601 * @description Delete all configurations related to the plugin
585 602 *
586 603 * @return void
587 604 */
588 - public function clean_option()
605 + public function clean_option(): void
589 606 {
590 607 $this->current_configuration = null;
591 608 delete_option('woocommerce_payplug_settings');
592 609 delete_site_option('woocommerce_payplug_settings');