fgraph 0.3.0 → 0.3.1
Sign up to get free protection for your applications and to get access to all the features.
- data/History +4 -0
- data/VERSION.yml +1 -1
- data/lib/fgraph/client.rb +1 -1
- data/lib/fgraph/rails/fgraph_helper.rb +15 -0
- data/lib/fgraph/rails/fgraph_tag_helper.rb +0 -15
- metadata +3 -3
data/History
CHANGED
data/VERSION.yml
CHANGED
data/lib/fgraph/client.rb
CHANGED
@@ -80,7 +80,7 @@ module FGraph
|
|
80
80
|
unless self.options[:app_access_token]
|
81
81
|
self.options[:app_access_token] = self.oauth_app_access_token
|
82
82
|
end
|
83
|
-
FGraph.insights(self.options[:client_id], self.options[:app_access_token], options)
|
83
|
+
FGraph.insights(self.options[:client_id], self.options[:app_access_token]['access_token'], options)
|
84
84
|
end
|
85
85
|
|
86
86
|
def method_missing(name, *args, &block)
|
@@ -81,6 +81,21 @@ module FGraph
|
|
81
81
|
:access_token => fgraph_access_token
|
82
82
|
)
|
83
83
|
end
|
84
|
+
|
85
|
+
# Return Facebook object picture url: http://graph.facebook.com/[id]/picture
|
86
|
+
#
|
87
|
+
# ==== Type Options
|
88
|
+
# * <tt>square</tt> - 50x50 (default)
|
89
|
+
# * <tt>small</tt> - 50 pixels wide, variable height
|
90
|
+
# * <tt>normal</tt> - 100 pixels wide, variable height
|
91
|
+
# * <tt>large</tt> - 200 pixels wide, variable height
|
92
|
+
#
|
93
|
+
def fgraph_picture_url(id, type=nil)
|
94
|
+
id = FGraph.get_id(id)
|
95
|
+
url = "http://graph.facebook.com/#{id}/picture"
|
96
|
+
url += "?type=#{type}" if type
|
97
|
+
url
|
98
|
+
end
|
84
99
|
end
|
85
100
|
end
|
86
101
|
end
|
@@ -50,21 +50,6 @@ module FGraph
|
|
50
50
|
end
|
51
51
|
end
|
52
52
|
|
53
|
-
# Return Facebook object picture url: http://graph.facebook.com/[id]/picture
|
54
|
-
#
|
55
|
-
# ==== Type Options
|
56
|
-
# * <tt>square</tt> - 50x50 (default)
|
57
|
-
# * <tt>small</tt> - 50 pixels wide, variable height
|
58
|
-
# * <tt>normal</tt> - 100 pixels wide, variable height
|
59
|
-
# * <tt>large</tt> - 200 pixels wide, variable height
|
60
|
-
#
|
61
|
-
def fgraph_picture_url(id, type=nil)
|
62
|
-
id = FGraph.get_id(id)
|
63
|
-
url = "http://graph.facebook.com/#{id}/picture"
|
64
|
-
url += "?type=#{type}" if type
|
65
|
-
url
|
66
|
-
end
|
67
|
-
|
68
53
|
def fgraph_image_tag(id, type=nil, options={})
|
69
54
|
default_options = fgraph_image_options(type)
|
70
55
|
default_options[:alt] = id['name'] if id.is_a?(Hash)
|
metadata
CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
|
|
5
5
|
segments:
|
6
6
|
- 0
|
7
7
|
- 3
|
8
|
-
-
|
9
|
-
version: 0.3.
|
8
|
+
- 1
|
9
|
+
version: 0.3.1
|
10
10
|
platform: ruby
|
11
11
|
authors:
|
12
12
|
- Herryanto Siatono
|
@@ -14,7 +14,7 @@ autorequire:
|
|
14
14
|
bindir: bin
|
15
15
|
cert_chain: []
|
16
16
|
|
17
|
-
date: 2010-06-
|
17
|
+
date: 2010-06-29 00:00:00 +08:00
|
18
18
|
default_executable:
|
19
19
|
dependencies:
|
20
20
|
- !ruby/object:Gem::Dependency
|