minimum-omniauth-scaffold 0.1.7 → 0.1.8

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
  SHA1:
3
- metadata.gz: 52af5b7d1ddd1b11159df09bc27d7aa664383ec9
4
- data.tar.gz: ab7c2a8fce67e6533b77ddb21ed0db7fa3c4aa6d
3
+ metadata.gz: 64173c89387a91c731cb46bf44703f830801eb2a
4
+ data.tar.gz: 10c34847521c8fdae3a31f6998690ba42077db8f
5
5
  SHA512:
6
- metadata.gz: 67cea8ccb5f7a2d7715eea2b21fa3bd91c62da2f1d57fd3d0f7c3a6b9d9e4a3df54bb34b063b29817674511315af0ce8fec3bff90ea6bfb3b9a38689256ec0bc
7
- data.tar.gz: ad76623071e21473e9ee084b0edc0acc7d126967402e6c4fc601dc94269edf6b8ae24a33c29c5a2f4d6c3649d48f62e1251a7d13b6848beb7324e7b98b32df7b
6
+ metadata.gz: 8be2ed7e2c65de0a5e101492fa5465a00f7fcf3b9dacfba54d25b6d6af1242080f7ca996ce134a6f6d03c99157c2bd9eca6bebe2a17330093d5ad3b4b6efaad2
7
+ data.tar.gz: 03cc7005cd26a090bf2cfe1b8a44538459ef9d72f4d3883f9f82933912b5f492dbdd6d1df2ed90ac1f28fef47e1d2f8593030569b70b10e187ff82a4c34afa3f
@@ -7,8 +7,8 @@ class SessionsController < ApplicationController
7
7
  authentication = Authentication.find_by(provider: auth["provider"], uid: auth["uid"]) || Authentication.create_with_omniauth(auth)
8
8
  authentication.auth_update(auth)
9
9
 
10
- # ユーザ作成
11
- user = User.create_with_auth(authentication)
10
+ # ユーザ取得or作成
11
+ user = User.find_by(id: authentication.user_id) || User.create_with_auth(authentication)
12
12
 
13
13
  session[:user_id] = user.id
14
14
  flash[:notice] = "ログインしました。"
@@ -10,7 +10,7 @@
10
10
  Login:
11
11
  <%= link_to "Twitter", "/auth/twitter" %>
12
12
  <%= link_to "Facebook", "/auth/facebook" %>
13
- <%= link_to "GitHub", "/auth/gitHub" %>
13
+ <%= link_to "GitHub", "/auth/github" %>
14
14
  <% end %>
15
15
 
16
16
  <%# 通知/エラーメッセージ %>
@@ -1,7 +1,7 @@
1
1
  module Minimum
2
2
  module Omniauth
3
3
  module Scaffold
4
- VERSION = "0.1.7"
4
+ VERSION = "0.1.8"
5
5
  end
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: minimum-omniauth-scaffold
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.7
4
+ version: 0.1.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - shu0115
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-11-20 00:00:00.000000000 Z
11
+ date: 2013-12-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -178,7 +178,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
178
178
  version: '0'
179
179
  requirements: []
180
180
  rubyforge_project:
181
- rubygems_version: 2.0.3
181
+ rubygems_version: 2.0.14
182
182
  signing_key:
183
183
  specification_version: 4
184
184
  summary: Minimum OmniAuth Scaffold