-
Notifications
You must be signed in to change notification settings - Fork 800
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
Subscriptions: Add a clear message when an email having many pending confirmations tries to subscribe a site. #14275
Conversation
…ving many pending subscriptions
Caution: This PR has changes that must be merged to WordPress.com |
This is an automated check which relies on |
This is intentional as I am following the style of the current code. |
Thanks! For the code styling, the intent of the changed line test is for updated code to get current styling to reduce the need (and size of) the more massive "PHPCS everything!" PRs. Merging those back to wp.com isn't the most fun thing! |
@kraftbj Gotcha, thanks for the explanation! So should I fix all style coding issues in this PR or I keep it as-is now? |
modules/subscriptions/views.php
Outdated
@@ -150,6 +150,12 @@ static function render_widget_status_messages( $instance ) { | |||
__( 'Manage your email preferences.', 'jetpack' ) | |||
); ?></p> | |||
<?php break; | |||
case 'many_pending_subs' : ?> | |||
<p class="error"><?php printf( __( 'You already have several pending email subscriptions. <br /> Approve or delete a few subscriptions at <a href="%1$s" title="%2$s" target="_blank">subscribe.wordpress.com</a> before continuing.', 'jetpack' ), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't know if several
is the right word here, since this can happen with just a few pending subs. Should we remove that word?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
several
means more than two but not many.
(I checked on the Oxford dictionary :D) Basically, I think its meaning is similar to "a few"?
Originally, I used "a few" too and then I followed the same message in WP.com side
https://github.com/Automattic/jetpack/blob/8.0/modules/subscriptions/views.php#L177
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'll let a native chime in on this :)
cc @kraftbj
I would suggest adhering to coding standards in the lines you changed. In a follow-up PR, you could then update the code around it to follow the same pattern. |
htdat, Your synced wpcom patch D37046-code has been updated. |
01fff0d
to
b368167
Compare
Thanks, Jeremy. I've updated code per your feedback and follow up coding standards. |
htdat, Your synced wpcom patch D37046-code has been updated. |
I've added a new commit to address the recent feedback. Thank you, @jeherve. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This tests well for me now.
wp_kses( | ||
/* translators: 1: Link to Subscription Management page https://subscribe.wordpress.com/, 2: Description of this link */ | ||
__( 'You already have several pending email subscriptions. <br /> Approve or delete a few subscriptions at <a href="%1$s" title="%2$s" target="_blank" rel="noopener noreferrer">subscribe.wordpress.com</a> before continuing.', 'jetpack' ), | ||
self::$allowed_html_tags_for_message |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a nice way to keep things tidy and makes it easily reusable in the future. Cool.
r201611-wpcom |
* [not verified] Rebase from the master branch and resolve conflict after #14275 is merged * Fix the space issue (again) * Add rel attribute Co-Authored-By: Jeremy Herve <jeremy@jeremy.hu> * Fix PHPCS error for switch statement * Update wording. Co-authored-by: Jeremy Herve <jeremy@tagada.hu> Co-authored-by: Brandon Kraft <public@brandonkraft.com>
* [not verified] Remove empty readme section * Initial changelog for 8.2 * Changelog: add #14220 * Changelog: add #14252 * Changelog: add #14291 * Changelog: add #14309 * Changelog: add #14304 * Changelog: add general connection log. * Changelog: add #14275 * Changelog: add #14313 * Changelog: add #14213 * Changelog: add #14357 * Add sync testing instructions * Add 8.1.1 changelog back See eeaafab and 61757eb * Changelog: add #14371 * Changelog: add #14386 * Changelog: add #14471 * Changelog: add #14325 * Changelog: add #14194 * Changelog: add #14340 * Changelog: add #14418 * Changelog: add #14417 * Changelog: add #14075 * Changelog: add #14467 * Changelog: add #14307 * Changelog: add #14326
Fixes #2278
Similar PRs: #9093 and #2599
Changes proposed in this Pull Request:
flooded_email
status.Before - unclear message:
After (with this fix) - clearer error message:
Is this a new feature or does it add/remove features to an existing part of Jetpack?
Testing instructions:
Proposed changelog entry for your changes: