PluginProbe
BlockSpare – Gutenberg Blocks, AI Content Generator & Site Builder for News, Magazine & Blogs / 5.0.1
BlockSpare – Gutenberg Blocks, AI Content Generator & Site Builder for News, Magazine & Blogs v5.0.1
5.0.1 4.1.0 trunk 1.0.0 1.0.1 1.0.2 1.0.3 1.0.4 1.0.5 1.1.0 1.1.1 1.1.2 1.2.0 1.2.1 1.2.2 1.2.3 1.3.0 1.3.1 1.3.2 1.3.3 1.3.4 1.3.5 2.1.2 2.5.0 2.5.3 All 39 releases
← All changes | freemius/templates/forms/affiliation.php +12 -11 2.5.0 → 5.0.1 View file →
@@ -68,12 +68,15 @@
68 68 $promotion_method_social_media = in_array( 'social_media', $promotion_methods );
69 69 $promotion_method_mobile_apps = in_array( 'mobile_apps', $promotion_methods );
70 70 }
71 71 } else {
72 - $current_user = Freemius::_get_current_wp_user();
73 - $full_name = trim( $current_user->user_firstname . ' ' . $current_user->user_lastname );
74 - $email_address = $current_user->user_email;
75 - $domain = Freemius::get_unfiltered_site_url( null, true );
72 + if ( ! is_object( $user ) ) {
73 + $current_user = Freemius::_get_current_wp_user();
74 + $full_name = trim( $current_user->user_firstname . ' ' . $current_user->user_lastname );
75 + $email_address = $current_user->user_email;
76 + }
77 +
78 + $domain = Freemius::get_unfiltered_site_url( null, true );
76 79 }
77 80
78 81 $affiliate_tracking = 30;
79 82
@@ -86,8 +89,10 @@
86 89 $apply_to_become_affiliate_text = fs_text_inline( 'Apply to become an affiliate', 'apply-to-become-an-affiliate', $slug );
87 90
88 91 $module_id = $fs->get_id();
89 92 $affiliate_program_terms_url = "https://freemius.com/plugin/{$module_id}/{$slug}/legal/affiliate-program/";
93 +
94 + $has_tabs = $fs->_add_tabs_before_content();
90 95 ?>
91 96 <div id="fs_affiliation_content_wrapper" class="wrap">
92 97 <form method="post" action="">
93 98 <div id="poststuff">
@@ -499,11 +504,7 @@
499 504 });
500 505 </script>
501 506 </div>
502 507 <?php
503 - $params = array(
504 - 'page' => 'affiliation',
505 - 'module_id' => $module_id,
506 - 'module_slug' => $slug,
507 - 'module_version' => $fs->get_plugin_version(),
508 - );
509 - fs_require_template( 'powered-by.php', $params );
508 + if ( $has_tabs ) {
509 + $fs->_add_tabs_after_content();
510 + }