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

Refactor some common special-case settings #259

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

jmadler
Copy link
Contributor

@jmadler jmadler commented Nov 29, 2020

This change is Reviewable

@jmadler jmadler requested a review from rgomezp November 29, 2020 19:46
@@ -138,41 +138,32 @@ public static function get_onesignal_settings() {
}
}

/*
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I removed this first comment block as I'm not sure if it's still meaningful. Are these supposed to be caller instructions?

// Do NOT enable the notify button for existing WordPress sites, since they might have a lot of users
$onesignal_wp_settings['notifyButton_enable'] = false;
}
// These boolean settings are on by default for new installs only, and off by default on plugin upgrades,
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Am I correct in my understanding here?

);
foreach ($uncustomizedByDefault as $key => $value) {
if (!array_key_exists($key, $onesignal_wp_settings)) {
if ( $is_new_user ) {
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is the array_key_exists/is_new_user dupe test still necessary?

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 this pull request may close these issues.

None yet

1 participant