[freeside-commits] branch master updated. ecd038f7ae5c1ffc929f3c928ecd161eeb45d9be

Ivan ivan at 420.am
Tue Dec 6 16:15:47 PST 2016


The branch, master has been updated
       via  ecd038f7ae5c1ffc929f3c928ecd161eeb45d9be (commit)
       via  606df68b2e1c2ee977aba90f3d738237dc23a61c (commit)
      from  319dfa0901a8bc9897e700390d3e97128d155819 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit ecd038f7ae5c1ffc929f3c928ecd161eeb45d9be
Merge: 606df68 319dfa0
Author: Ivan Kohler <ivan at freeside.biz>
Date:   Tue Dec 6 16:15:42 2016 -0800

    Merge branch 'master' of git.freeside.biz:/home/git/freeside


commit 606df68b2e1c2ee977aba90f3d738237dc23a61c
Author: Ivan Kohler <ivan at freeside.biz>
Date:   Tue Dec 6 16:15:27 2016 -0800

    Make a config for the number of hours a self-service password reset is valid

diff --git a/FS/FS/Conf.pm b/FS/FS/Conf.pm
index 1b6deec..d5384e1 100644
--- a/FS/FS/Conf.pm
+++ b/FS/FS/Conf.pm
@@ -2886,6 +2886,13 @@ and customer address. Include units.',
   },
 
   {
+    'key'         => 'selfservice-password_reset_hours',
+    'section'     => 'self-service',
+    'description' => 'Numbers of hours an email password reset is valid.  Defaults to 24.',
+    'type'        => 'text',
+  },
+
+  {
     'key'         => 'selfservice-password_reset_msgnum',
     'section'     => 'self-service',
     'description' => 'Template to use for password reset emails.',
diff --git a/FS/FS/contact.pm b/FS/FS/contact.pm
index fd3e9d7..1c456e7 100644
--- a/FS/FS/contact.pm
+++ b/FS/FS/contact.pm
@@ -867,7 +867,10 @@ sub send_reset_email {
     'svcnum'     => $opt{'svcnum'},
   };
 
-  my $timeout = '24 hours'; #?
+  
+  my $conf = new FS::Conf;
+  my $timeout =
+    ($conf->config('selfservice-password_reset_hours') || 24 ). ' hours';
 
   my $reset_session_id;
   do {

-----------------------------------------------------------------------

Summary of changes:
 FS/FS/Conf.pm    |    7 +++++++
 FS/FS/contact.pm |    5 ++++-
 2 files changed, 11 insertions(+), 1 deletion(-)




More information about the freeside-commits mailing list