From 5cbe16c3d2a3a3667021fb8c81f743308aefbdae Mon Sep 17 00:00:00 2001 From: Alex Buijs Date: Wed, 31 Jul 2019 16:48:38 +0200 Subject: Set Devise's allow_unconfirmed_access_for to 30 days --- app/models/user.rb | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'app/models/user.rb') diff --git a/app/models/user.rb b/app/models/user.rb index ac83c8e3256..4adc44a9375 100644 --- a/app/models/user.rb +++ b/app/models/user.rb @@ -1505,6 +1505,13 @@ class User < ApplicationRecord super end + # override from Devise::Confirmable + def confirmation_period_valid? + return false if Feature.disabled?(:soft_email_confirmation) + + super + end + private def default_private_profile_to_false -- cgit v1.2.1