PluginProbe
Formidable Forms – WordPress Form Builder for Contact Forms, Calculators, Quizzes & More / trunk
Formidable Forms – WordPress Form Builder for Contact Forms, Calculators, Quizzes & More vtrunk
6.35 6.34 6.33.1 6.33 6.32.1 6.32 6.31 6.25 6.25.1 6.26 6.26.1 6.27 6.28 6.29 6.3 6.3.1 6.3.2 6.30 6.4 6.4.1 6.4.2 6.5 6.5.1 6.5.2 6.5.3 All 141 releases
← All changes | square/helpers/FrmSquareLiteAppHelper.php +10 -10 6.26 → trunk View file →
@@ -46,24 +46,24 @@
46 46 *
47 47 * @psalm-return 'live'|'test'
48 48 */
49 49 public static function active_mode() {
50 - $settings = self::get_settings();
51 - return $settings->settings->test_mode ? 'test' : 'live';
50 + return self::get_settings()->settings->test_mode ? 'test' : 'live';
52 51 }
53 52
54 53 /**
55 - * Add education about Stripe fees.
54 + * Add education about Square fees.
56 55 *
57 - * @param string $medium Medium identifier for the tip (for example 'tip').
56 + * Square is not included in a grandfathered license, so its fees always apply
57 + * there even though Stripe fees do not.
58 + *
59 + * @param string $content UTM Content for the admin upgrade link.
58 60 * @param array|false|string $gateway Gateway or list of gateways this applies to.
59 61 *
60 62 * @return void
61 63 */
62 - public static function fee_education( $medium = 'tip', $gateway = false ) {
63 - $license_type = FrmAddonsController::license_type();
64 -
65 - if ( in_array( $license_type, array( 'elite', 'business' ), true ) ) {
64 + public static function fee_education( $content = 'tip', $gateway = false ) {
65 + if ( ! FrmAddonsController::payment_fees_apply( 'square' ) ) {
66 66 return;
67 67 }
68 68
69 69 $classes = 'frm-light-tip show_square';
@@ -74,10 +74,10 @@
74 74
75 75 FrmTipsHelper::show_tip(
76 76 array(
77 77 'link' => array(
78 - 'content' => 'square-fee',
79 - 'medium' => $medium,
78 + 'campaign' => 'square-fee',
79 + 'content' => $content,
80 80 ),
81 81 'tip' => 'Pay as you go pricing: 3% fee per-transaction + Square fees.',
82 82 'call' => __( 'Upgrade to save on fees.', 'formidable' ),
83 83 'class' => $classes,