Skip to content

Commit e25adf5

Browse files
refactor: changes
1 parent 466b2ed commit e25adf5

File tree

2 files changed

+22
-14
lines changed

2 files changed

+22
-14
lines changed

.github/workflows/build-dev-artifacts.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,8 @@ jobs:
6161
pr_number: ${{ steps.get-pr-number.outputs.num }}
6262
comment_body: ${{ steps.get-comment-body.outputs.body }}
6363
steps:
64+
- name: Check out source files
65+
uses: actions/checkout@v4
6466
- name: Get PR number
6567
id: get-pr-number
6668
run: echo "::set-output name=num::$(echo $GITHUB_REF | awk 'BEGIN { FS = "/" } ; { print $3 }')"

includes/admin/feedzy-rss-feeds-admin.php

Lines changed: 20 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ function( $data, $page_slug ) {
7777
);
7878
}
7979

80-
apply_filters( 'themeisle_sdk_blackfriday_data', array( $this, 'set_black_friday_data' ) );
80+
add_filter( 'themeisle_sdk_blackfriday_data', array( $this, 'set_black_friday_data' ) );
8181

8282
/**
8383
* Load SDK dependencies.
@@ -2376,22 +2376,28 @@ private function enable_telemetry() {
23762376
* @return array
23772377
*/
23782378
public function set_black_friday_data( $config ) {
2379-
$product_label = __( 'Feedzy RSS Feeds', 'feedzy-rss-feeds' );
2380-
$discount = '40%';
2381-
2382-
if ( feedzy_is_pro() ) {
2383-
$product_label = __( 'Feedzy RSS Feeds Pro', 'feedzy-rss-feeds' );
2384-
$discount = '50%';
2385-
}
2386-
2387-
$license_data = get_option( 'feedzy_rss_feeds_pro_license_data', array() );
2379+
$product_label = __( 'Feedzy', 'feedzy-rss-feeds' );
2380+
$discount = '70%';
23882381

23892382
// translators: %1$s - discount, %2$s - product label.
23902383
$config['message'] = sprintf( __( 'Our biggest sale of the year: <strong>%1$s OFF</strong> on <strong>%2$s</strong>! Don\'t miss this limited-time offer.', 'feedzy-rss-feeds' ), $discount, $product_label );
2391-
$config['url'] = add_query_arg( array(
2392-
'utm_plugin' => feedzy_is_pro() ? 'feedzy-pro' : 'feedzy-rss-feeds',
2393-
'utm_plan' => self::plan_category( $license_data ),
2394-
), $config['base_url'] );
2384+
2385+
$is_pro = feedzy_is_pro();
2386+
2387+
if ( $is_pro ) {
2388+
$product_label = __( 'Feedzy Pro', 'feedzy-rss-feeds' );
2389+
$discount = '30%';
2390+
2391+
// translators: %1$s - discount, %2$s - product label.
2392+
$config['message'] = sprintf( __( 'Get <strong>%1$s off</strong> when you upgrade your <strong>%2$s</strong> plan or renew early.', 'feedzy-rss-feeds' ), $discount, $product_label );
2393+
}
2394+
2395+
$config['sale_url'] = add_query_arg(
2396+
array(
2397+
'utm_term' => $is_pro ? 'plan-' . apply_filters( 'product_feedzy_license_plan', 0 ) : 'free'
2398+
),
2399+
tsdk_translate_link( tsdk_utmify( 'https://themeisle.com/plugins/feedzy-rss-feeds/blackfriday', 'bfcm', 'feedzy' ) )
2400+
);
23952401

23962402
return $config;
23972403
}

0 commit comments

Comments
 (0)