]> git.koha-community.org Git - koha.git/commit
Bug 22047: Add 'skip_validation' param to Koha::Patron->set_password
authorTomas Cohen Arazi <tomascohen@theke.io>
Wed, 26 Dec 2018 15:37:07 +0000 (12:37 -0300)
committerMartin Renvoize <martin.renvoize@ptfs-europe.com>
Thu, 31 Jan 2019 16:48:22 +0000 (16:48 +0000)
commit571ef9e6d297f60a68aa933f0518795e7b94cadb
tree1a5f7018c05a2a8896b5ed06f176fd3fcfd0a901
parent170ac6bbf37df2f0c0c4567bdf00ebedcdcb1439
Bug 22047: Add 'skip_validation' param to Koha::Patron->set_password

This patch makes Koha::Patron->set_password expect a hashref as param
and adds support for an 'skip_validation' param to be passed. Its purpose is to
make the method skip the relevant password strength checks if required.

It targets the Auth_with_ldap.pm usage when the 'update_password' flag
is set in the configuration.

The tests on this bug cover this use case so, to test:

- Apply the tests patch
- Run:
  $ kshell
 k$ prove t/db_dependent/Koha/Patrons.t
=> FAIL: Tests fail, code doesn't work as expected
- Apply this patch
- Run:
 k$ prove t/db_dependent/Koha/Patrons.t
=> SUCCESS: Tests pass! Yay!
- Sign off :-D

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
(cherry picked from commit 0f0e064a2b232949185a9ee7ef2c911325d15591)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Koha/Patron.pm