egov_utils 0.4.1 → 0.4.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 2290ad2369d8330daa5b454e76bc5f042931f191e10697178b86bc08c5412fb5
4
- data.tar.gz: cd4db6767c26c648c93bb6f70038ce294b0f8f215fb684cb7177a14af3ccbe50
3
+ metadata.gz: 28bcac8b22dc1ac24bf8f6d2020c38543b3cf0a72d45a3cb1d2e010e0340cb27
4
+ data.tar.gz: bc1069c0ac07373700ef55ee890540d8ea59817ff9dc22a6eb8c2cbba7c973b6
5
5
  SHA512:
6
- metadata.gz: 65b89e4897982f5c62154dfacf26addab9ddffa031ff19c9425998a42c36d39f440ec1dbac5d2de30cd199b707983df3ed2f68bb3ca5770e738ca76de4934fa5
7
- data.tar.gz: 55905eab4a285b84c1f1dc47f2d31cc4fa5ea2a92d612018695314227c949364295cc7895038d2dd76cdb5976d4554d8aa5453ec80e26f583d90829c8595f1a3
6
+ metadata.gz: af95472e39fbfd83b19cadebb337dd4e2f42106a90b1ace210b897a31f09dd83ccd5f92da7c66e8c77434f4a72ed8718fcbd47f55a73b30e7de7dcfe4619e520
7
+ data.tar.gz: 30cc745213efb8a6228503ef0530725fdd4221e5cc07923ff19228c0efb644cfae3c632f936203350bbf3c9872c0734ddb7ce13f6bcaf8fc766f8c39a9fc8283
@@ -61,7 +61,7 @@ module EgovUtils
61
61
 
62
62
  def confirm
63
63
  @user = User.find_by(confirmation_code: params[:id])
64
- render_404 and return unless @user || @user.active? || @user.updated_at < (Time.now - 24.hours)
64
+ render_404 and return if @user.nil? || !@user.active? || @user.updated_at < (Time.now - 24.hours)
65
65
  @user.update(active: true)
66
66
  logged_user = @user
67
67
  flash[:notice] = t('success_user_confirm')
@@ -1,3 +1,3 @@
1
1
  module EgovUtils
2
- VERSION = '0.4.1'
2
+ VERSION = '0.4.2'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: egov_utils
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.1
4
+ version: 0.4.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ondřej Ezr