This commit removes the logic that was added in #2045 to handle
subscribers migrated from MP2 when deactivating subscribers. Without it,
MP3 would deactive all subscribers imported from MP2 as the subscribe
date is migrated but the stats are not (see
https://mailpoet.atlassian.net/browse/MAILPOET-2040) for more details.
This code is not necessary anymore as we are removing all the MP2 migration
related code.
[MAILPOET-4376]
We agreed that we can use WP translation functions directly.
This one was probably some leftover which remained in the file after merging branches.
The file was missing use statement so this was causing an error.
[MAILPOET-4551]
Although it doesn't make senses to select a segment with 0 subscribers
directly from the dropdown, we allow users to click a "view subscribers"
link or, with MAILPOET-4244, click a badge to see all the subscribers of
that segment. The UI on the subscribers page indicates which segment is
selected by selecting it in the dropdown.
If we exclude lists with 0 subscribers (or 0 calculated
subscribers), the filter selection is blank and the user has no way of
knowing what filter is being applied. By including these empty lists
we're giving users a way of knowing why there are 0 subscribers being
shown.
MAILPOET-4244
Remove the following errors from Subscribers\ImportExport\Import\MailChimp:
(Method|Property|Function) has no (return )?type specified.
(Method|Function) has parameter with no type (specified).
[MAILPOET-3720]
Remove the following errors from Subscribers\ImportExport\Import\Import:
(Method|Property|Function) has no (return )?type specified.
(Method|Function) has parameter with no type (specified).
I have also added a few checks when using count and typed the arrays when possible.
[MAILPOET-3720]
Remove the following errors:
(Method|Property|Function) has no (return )?type specified.
(Method|Function) has parameter with no type (specified).
array_walk on import.php was expecting the key as the second parameter to the function. I have switched it to array_map.
[MAILPOET-3720]
This commit renames two variables to make it easier to understand the
code responsible for adding a ReCapcha to a subscription form:
formData.recaptcha -> formData.recaptchaWidgetId
formData.data.recaptcha -> formData.data.recaptchaResponseToken
Before this change it was harder to understand the difference between
formData.recaptcha and formData.data.recaptcha since they used the same
name.
[MAILPOET-4145]
This commit adds the required code to display the invisible ReCaptcha in
the frontend when a form is rendered and this type of captcha is
selected in the admin.
[MAILPOET-4145]
We can't create mailer directly in DI container using the factory because it may fail in case
the plugin is not configured properly and prevent plugin from start.
The Mailer was previously injected because it contains lazy initialization.
The lazy initialization in the singleton Mailer service was dangerous,
because when used with some custom parameters it could cause that all services
that inject the Mailer from DI would use the custom config instead the default.
[MAILPOET-4115]