graphql-auth 0.2.0 → 0.2.1

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: b217f15c97c13f82c9a46e990b43d3330d188c1e581858eebf950cb002d4a4fd
4
- data.tar.gz: 16c2e73bb8afd958b1c1ea1c13976d5c3feca2af34a58ae2cbed4545bbc67b82
3
+ metadata.gz: 2d39b72da2fa5e34d69a4f7b97042a68ab2a0e7c99653ef7c3a5c3685c3f7f29
4
+ data.tar.gz: 901968da1fdbd829e5caf29a5879bc4cb3166c99742f9f963b70e1917e97edf2
5
5
  SHA512:
6
- metadata.gz: 4e80d69d1268094b93c0bab8e0f4c8330b36e11cb3deefedef20dc03a1593960de962a74de2f5cdbec006c6f0ea561297fc5b31e41e86befdff5619ddff8313c
7
- data.tar.gz: 4ef5135a028e31897b0a446197135e97a1f31ef73e51d160fcab572932c3f0d3e207a981bdf39a60a7efa5aa44dc1711040b040a321a4025a816b83cf61d1969
6
+ metadata.gz: 730ddf32dcb3a61fa8f6aa3bed11b34f5c749f10a07d7e040132588240697a3263d81b5d4c3c39328355f47833e8a77685c6e4eca9a536e2dc27df3eab3f2cd0
7
+ data.tar.gz: d83b22ca7edf609f0b19fd326687debbd741435564a9f905e2c7b028039d92a771bc08a048fa59ad57bbcaaffd7ba79faf2e66282a2e57380eb5e19f4be36496
@@ -3,6 +3,10 @@
3
3
  class Types::Auth::User < GraphQL::Schema::Object
4
4
  description 'Data of a user'
5
5
 
6
+ field :id, ID, null: false do
7
+ description 'ID of the user'
8
+ end
9
+
6
10
  field :email, String, null: false do
7
11
  description 'Email address of the user'
8
12
  end
@@ -3,6 +3,8 @@ GraphQL::Auth.configure do |config|
3
3
  # config.jwt_secret_key = ENV['JWT_SECRET_KEY']
4
4
  # config.app_url = ENV['APP_URL']
5
5
 
6
+ # config.user_type = ::Type::Auth::User
7
+
6
8
  # config.sign_in_mutation = ::Mutations::Auth::SignIn
7
9
  # config.sign_up_mutation = ::Mutations::Auth::SignUp
8
10
 
@@ -4,26 +4,29 @@ module GraphQL
4
4
  attr_accessor :token_lifespan,
5
5
  :jwt_secret_key,
6
6
  :app_url,
7
+ :user_type,
7
8
  :sign_in_mutation,
8
9
  :sign_up_mutation,
9
10
  :forgot_password_mutation,
10
11
  :reset_password_mutation,
11
12
  :update_account_mutation,
12
13
  :validate_token_mutation
13
-
14
+
14
15
  def initialize
15
16
  @token_lifespan = 4.hours
16
17
  @jwt_secret_key = ENV['JWT_SECRET_KEY']
17
18
  @app_url = ENV['APP_URL']
18
-
19
+
20
+ @user_type = ::Types::Auth::User
21
+
19
22
  @sign_in_mutation = ::Mutations::Auth::SignIn
20
23
  @sign_up_mutation = ::Mutations::Auth::SignUp
21
-
24
+
22
25
  @forgot_password_mutation = ::Mutations::Auth::ForgotPassword
23
26
  @reset_password_mutation = ::Mutations::Auth::ResetPassword
24
-
27
+
25
28
  @update_account_mutation = ::Mutations::Auth::UpdateAccount
26
-
29
+
27
30
  @validate_token_mutation = ::Mutations::Auth::ValidateToken
28
31
  end
29
32
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: graphql-auth
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Guillaume Ferland
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-01-09 00:00:00.000000000 Z
11
+ date: 2019-01-10 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler