| @@ -79,17 +79,18 @@ | ||
| 79 | 79 | |
| 80 | 80 | /** |
| 81 | 81 | * Add education about PayPal fees. |
| 82 | 82 | * |
| 83 | - * @param string $medium Medium identifier for the tip (for example 'tip'). | |
| 83 | + * PayPal Commerce is not included in a grandfathered license, so its fees | |
| 84 | + * always apply there even though Stripe fees do not. | |
| 85 | + * | |
| 86 | + * @param string $content UTM Content for the admin upgrade link. | |
| 84 | 87 | * @param array|false|string $gateway Gateway or list of gateways this applies to. |
| 85 | 88 | * |
| 86 | 89 | * @return void |
| 87 | 90 | */ |
| 88 | - public static function fee_education( $medium = 'tip', $gateway = false ) { | |
| 89 | - $license_type = FrmAddonsController::license_type(); | |
| 90 | - | |
| 91 | - if ( in_array( $license_type, array( 'elite', 'business' ), true ) ) { | |
| 91 | + public static function fee_education( $content = 'tip', $gateway = false ) { | |
| 92 | + if ( ! FrmAddonsController::payment_fees_apply( 'paypal' ) ) { | |
| 92 | 93 | return; |
| 93 | 94 | } |
| 94 | 95 | |
| 95 | 96 | $classes = 'frm-light-tip show_paypal'; |
| @@ -100,10 +101,10 @@ | ||
| 100 | 101 | |
| 101 | 102 | FrmTipsHelper::show_tip( |
| 102 | 103 | array( |
| 103 | 104 | 'link' => array( |
| 104 | - 'content' => 'paypal-fee', | |
| 105 | - 'medium' => $medium, | |
| 105 | + 'campaign' => 'paypal-fee', | |
| 106 | + 'content' => $content, | |
| 106 | 107 | ), |
| 107 | 108 | 'tip' => 'Pay as you go pricing: 3% fee per-transaction + PayPal fees.', |
| 108 | 109 | 'call' => __( 'Upgrade to save on fees.', 'formidable' ), |
| 109 | 110 | 'class' => $classes, |