Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: compatibility with iThemes Sync #3989 #4195

Closed
2 of 4 tasks
ravinderk opened this issue Jul 29, 2019 · 0 comments · Fixed by #4196
Closed
2 of 4 tasks

fix: compatibility with iThemes Sync #3989 #4195

ravinderk opened this issue Jul 29, 2019 · 0 comments · Fixed by #4196
Assignees
Milestone

Comments

@ravinderk
Copy link
Collaborator

ravinderk commented Jul 29, 2019

Bug Report

User Story

As a plugin user, I want this plugin to work smoothly with iThemes Sync plugin.

Ticket: https://secure.helpscout.net/conversation/913833224/44167?folderId=3046394

Current Behavior

User is getting fatal error:

Error Details
=============
An error of type E_ERROR was caused in line 1104 of the file /home/compass82/public_html/wp-content/plugins/give/includes/admin/class-admin-settings.php. Error message: Uncaught Error: Call to undefined function give_get_current_setting_tab() in /home/compass82/public_html/wp-content/plugins/give/includes/admin/class-admin-settings.php:1104
Stack trace:
#0 /home/compass82/public_html/wp-content/plugins/give-recurring/includes/admin/emails/class-subscription-reminder-email.php(495): Give_Admin_Settings::is_setting_page('emails', 'subscription-re...')
#1 /home/compass82/public_html/wp-content/plugins/give-recurring/includes/admin/emails/class-subscription-reminder-email.php(445): Give_Subscription_Reminder_Email->is_renewal_settings()
#2 /home/compass82/public_html/wp-content/plugins/give-recurring/includes/admin/emails/class-subscription-reminder-email.php(131): Give_Subscription_Reminder_Email->action_notice_delete()
#3 /home/compass82/public_html/wp-content/plugins/give/includes/admin/emails/class-email-notifications.php(213): Give_Subscription_Reminder_Email->init()
#4 /home/compass82/public_html/wp-content/plugins/give/includes/admin/emails/class-email-notifications.php(7

Expected Behavior

The plugin must work fine without any PHP error.

Bug Type

  • This bug describes functionality that once worked as expected in version X.X.X.
  • This bug describes functionality that never worked as expected.
  • I am not sure whether this functionality ever worked as expected.

Steps to Reproduce

  1. Install Give core 2.5.0 and Recurring add-on 1.9.1
  2. Create mu-plugin and add the following snippet code.
function give_init(){
	if( ! defined( 'WP_ADMIN' ) ) {
		define( 'WP_ADMIN', true );
	}
}
add_action( 'give_init', 'give_init' );
  1. Visit website home page

Possible Solution

Exit early from function Give_Admin_Setting:: is_setting_page if we are not viewing give setting page.

Related

#4059

Acceptance Criteria

  • Plugin must load without any issue.
@ravinderk ravinderk self-assigned this Jul 29, 2019
@ravinderk ravinderk added this to the July 2019 milestone Jul 29, 2019
@ravinderk ravinderk changed the title fix compatibility with iThemes Sync #3989 fix: compatibility with iThemes Sync #3989 Jul 29, 2019
mikejhale added a commit that referenced this issue Jul 30, 2019
fix: exit early from fn if we are on give setting page #4195
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant