omniauth-campus 0.4.8 → 0.4.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: a3aa81608d9b3c20dc330d44527514599be2b277
4
- data.tar.gz: f8e064edb636380b1d78f3db39decb0cb9291d98
3
+ metadata.gz: d00cd74f2e4f1cae1641edb762e6b6675b29ca0c
4
+ data.tar.gz: a0a2c5f993ac89da38f95f458b5f7854740cc182
5
5
  SHA512:
6
- metadata.gz: bcb4a60e86eefa0b67a36bd7056b308200ce7f5ca81aea5605c3f865e33035c50777c26139775e18b7175d2bfd04ecdcca203a35fea5c635df470a0f980701a0
7
- data.tar.gz: 9a4b12ff47b39bb095dec374bf2149543125f2f19f8ce7873f211342f7dc38cfbb9a6640ba7c64ca209a60f53c100bc4d0e2549b55eeaf40d682b002e5533995
6
+ metadata.gz: e95c82905a7f147fef5a8a6a3541c1e35f5c545a8556435bcb0f04a03aad285a0bcfb916b51414a982d156e2f4bad88dd1e2401d82174e1647404c700eafa2e9
7
+ data.tar.gz: f4de3092941d1925baa4c5907977f1771923824634e93c4cf1d1b50fd4f57764640c802868819ef0ba70f9f160483514b37d147c2cea058c4c4487b82b3df1a4
Binary file
@@ -1,6 +1,6 @@
1
1
  module Omniauth
2
2
  module Campus
3
- VERSION = "0.4.8"
3
+ VERSION = "0.4.9"
4
4
  end
5
5
  end
6
6
 
Binary file
@@ -25,7 +25,7 @@ module OmniAuth
25
25
  access_token_path: '/oauth/access_token',
26
26
  authorize_path: '/oauth/authorize',
27
27
  request_token_path: '/oauth/request_token',
28
- site: 'http://vistacampus.org'
28
+ site: 'https://vistacampus.org'
29
29
  }
30
30
 
31
31
  option :fields, [:name, :email]
@@ -40,11 +40,27 @@ module OmniAuth
40
40
  #
41
41
  # }
42
42
  #
43
- def request_phase
44
- options[:authorize_params] = {:perms => options[:scope]} if options[:scope]
45
- super
46
- end
43
+ def request_phase
44
+ %w[force_login lang screen_name].each do |v|
45
+ if request.params[v]
46
+ options[:authorize_params][v.to_sym] = request.params[v]
47
+ end
48
+ end
49
+
50
+ %w[x_auth_access_type].each do |v|
51
+ if request.params[v]
52
+ options[:request_params][v.to_sym] = request.params[v]
53
+ end
54
+ end
47
55
 
56
+ if request.params['use_authorize'] == 'true'
57
+ options[:client_options][:authorize_path] = '/oauth/authorize'
58
+ else
59
+ options[:client_options][:authorize_path] = '/oauth/authenticate'
60
+ end
61
+
62
+ old_request_phase
63
+ end
48
64
  uid {raw_info['uid']}
49
65
 
50
66
  info do {
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: omniauth-campus
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.8
4
+ version: 0.4.9
5
5
  platform: ruby
6
6
  authors:
7
7
  - johnvehr
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-03-12 00:00:00.000000000 Z
11
+ date: 2014-03-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler