fb_graph_rails 0.0.2 → 0.0.3
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.
data/README.md
CHANGED
|
@@ -23,7 +23,8 @@ keys of your application and your facebook secret.
|
|
|
23
23
|
development: &defaults
|
|
24
24
|
client_id: your_client_id
|
|
25
25
|
client_secret: your_client_secret
|
|
26
|
-
|
|
26
|
+
# scope: user_about_me,user_activities,user_birthday,user_education_history,user_events,user_groups,user_hometown,user_interests,user_likes,user_location,user_notes,user_online_presence,user_photo_video_tags,user_photos,user_relationships,user_relationship_details,user_religion_politics,user_status,user_videos,user_website,user_work_history,email,read_friendlists,read_insights,read_mailbox,read_requests,read_stream,xmpp_login,ads_management,user_checkins,publish_stream,create_event,rsvp_event,sms,offline_access,publish_checkins,manage_pages,friends_about_me,friends_activities,friends_birthday,friends_education_history,friends_events,friends_groups,friends_hometown,friends_interests,friends_likes,friends_location,friends_notes,friends_online_presence,friends_photo_video_tags,friends_photos,friends_relationships,friends_relationship_details,friends_religion_politics,friends_status,friends_videos,friends_website,friends_work_history,manage_friendlists,friends_checkins,manage_notifications # ,user_address,user_mobile_phone
|
|
27
|
+
scope: [email, user_about_me]
|
|
27
28
|
canvas_url: http://apps.facebook.com/your_app
|
|
28
29
|
model: your_user_model
|
|
29
30
|
|
|
@@ -11,7 +11,6 @@ module FbGraphRails::FbActionControllerExtension
|
|
|
11
11
|
module InstanceMethods
|
|
12
12
|
|
|
13
13
|
def fb_auth_required
|
|
14
|
-
p self.authenticated?
|
|
15
14
|
unless self.authenticated?
|
|
16
15
|
auth = self.class.fb_auth
|
|
17
16
|
auth.from_signed_request(params[:signed_request]) unless params[:signed_request].blank?
|
|
@@ -19,7 +18,9 @@ module FbGraphRails::FbActionControllerExtension
|
|
|
19
18
|
authenticate self.class.fb_model.identify(auth.user)
|
|
20
19
|
return true
|
|
21
20
|
else
|
|
22
|
-
|
|
21
|
+
url = auth.authorize_uri(self.class.fb_canvas_url, :scope => self.class.fb_auth_scope).html_safe
|
|
22
|
+
return render :inline => "<script>top.location.href = '#{url}';</script>"
|
|
23
|
+
|
|
23
24
|
end
|
|
24
25
|
end
|
|
25
26
|
end
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: fb_graph_rails
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.0.
|
|
4
|
+
version: 0.0.3
|
|
5
5
|
prerelease:
|
|
6
6
|
platform: ruby
|
|
7
7
|
authors:
|
|
@@ -10,11 +10,11 @@ authors:
|
|
|
10
10
|
autorequire:
|
|
11
11
|
bindir: bin
|
|
12
12
|
cert_chain: []
|
|
13
|
-
date:
|
|
13
|
+
date: 2012-01-09 00:00:00.000000000Z
|
|
14
14
|
dependencies:
|
|
15
15
|
- !ruby/object:Gem::Dependency
|
|
16
16
|
name: rails
|
|
17
|
-
requirement: &
|
|
17
|
+
requirement: &2152013180 !ruby/object:Gem::Requirement
|
|
18
18
|
none: false
|
|
19
19
|
requirements:
|
|
20
20
|
- - ! '>='
|
|
@@ -22,10 +22,10 @@ dependencies:
|
|
|
22
22
|
version: 3.0.0
|
|
23
23
|
type: :runtime
|
|
24
24
|
prerelease: false
|
|
25
|
-
version_requirements: *
|
|
25
|
+
version_requirements: *2152013180
|
|
26
26
|
- !ruby/object:Gem::Dependency
|
|
27
27
|
name: fb_graph
|
|
28
|
-
requirement: &
|
|
28
|
+
requirement: &2152010880 !ruby/object:Gem::Requirement
|
|
29
29
|
none: false
|
|
30
30
|
requirements:
|
|
31
31
|
- - ~>
|
|
@@ -33,7 +33,7 @@ dependencies:
|
|
|
33
33
|
version: 2.2.4
|
|
34
34
|
type: :runtime
|
|
35
35
|
prerelease: false
|
|
36
|
-
version_requirements: *
|
|
36
|
+
version_requirements: *2152010880
|
|
37
37
|
description: ''
|
|
38
38
|
email:
|
|
39
39
|
- fabian.otto@familienservice.de
|