Hi,
the form on admin/settings/password_policy/%/edit states for "Password Expiration Warning": "Leaving this field empty won't send out or display any warnings."
This is not true. Leaving the field blank password_policy sends during the next cron run the warning emails. Just the opposite as described and wanted.
In password_policy_cron() the line
$warnings = explode(',', $policy['warning']);
...
if (!empty($warnings)) {...}
are the problem. The returned $warnings array is not empty when $policy['warning'] is the empty string.
Proof:
$ php
<?php
$warnings = explode(',', '');
print_r($warnings);
^D
Array
(
[0] =>
)
Comments
Comment #1
miglius commentedFixed in the cvs. Thanks for spotting it.
Comment #2
bjcool commentedVerified