thecore_auth_commons 2.3.3 → 2.3.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/db/seeds.rb +7 -6
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ef336ba07dfb2b7045b03c7c6ddd046cc57f9494563917a728877f9ee2830191
|
4
|
+
data.tar.gz: e71c6255f11bca1c7c625e0eaf150d5ece5a38104285be9d15f3b7a95fdd3b3c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a5d025b7c10645755d7e550da428eff612e2fb8e671eeef0c0f711d725b7086312b63053e5880d75ec897ce82e177a56c6090786b9ba53b1cedd8f039f459c6a
|
7
|
+
data.tar.gz: 037a7431dd095a9cd2452847aab62e08d7d7e34a643a1bb2b49870ff01d81dbbcef64ad740c08efab5e8c27abe7741c1dd1ca979a72816903763baf7a5395010
|
data/db/seeds.rb
CHANGED
@@ -2,12 +2,13 @@ puts "Loading ThecoreAuthCommons seeds"
|
|
2
2
|
email = ENV["ADMIN_EMAIL"].presence || "admin@example.com"
|
3
3
|
psswd = ENV["ADMIN_PASSWORD"].presence || "changeme"
|
4
4
|
|
5
|
-
|
6
|
-
u
|
7
|
-
u.
|
8
|
-
u.
|
9
|
-
u.
|
10
|
-
|
5
|
+
unless User.where(admin: true).exists?
|
6
|
+
u = User.find_or_initialize_by(email: email)
|
7
|
+
u.username = "Administrator"
|
8
|
+
u.password = u.password_confirmation = psswd
|
9
|
+
u.admin = true
|
10
|
+
u.save(validate: false)
|
11
|
+
end
|
11
12
|
|
12
13
|
@values = {
|
13
14
|
predicates: %i[can cannot],
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: thecore_auth_commons
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.3.
|
4
|
+
version: 2.3.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Gabriele Tassoni
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-03-
|
11
|
+
date: 2021-03-30 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|