diff options
author | Jannis M. Hoffmann <jannis@fehcom.de> | 2023-09-09 14:36:45 +0200 |
---|---|---|
committer | Jannis M. Hoffmann <jannis@fehcom.de> | 2023-09-09 14:36:45 +0200 |
commit | 45c55ee591d9aaddaeeffac9240e310951f71fe0 (patch) | |
tree | 32386f3edeca49188b9d0ea6ad357818dae81082 /lib/JWebmail | |
parent | 4f0692e955ae7f7ef8d102342e20f03e874cf061 (diff) |
fix tests and tests dependencies
Diffstat (limited to 'lib/JWebmail')
-rw-r--r-- | lib/JWebmail/Model/ReadMails/MockJSON.pm | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/lib/JWebmail/Model/ReadMails/MockJSON.pm b/lib/JWebmail/Model/ReadMails/MockJSON.pm index 9ad5f09..70daf8f 100644 --- a/lib/JWebmail/Model/ReadMails/MockJSON.pm +++ b/lib/JWebmail/Model/ReadMails/MockJSON.pm @@ -8,7 +8,13 @@ use autodie; use List::Util 'sum'; use JSON::PP 'decode_json'; -use Digest::HMAC_MD5 'hmac_md5_hex'; +use JWebmail::Config 'LOGIN_SCHEME'; + +if (LOGIN_SCHEME eq fc 'cram_md5') { + require Digest::HMAC_MD5; + Digest::HMAC_MD5->import('hmac_md5_hex'); +} + use Role::Tiny::With; use namespace::clean; |