fgraph 0.3.2 → 0.3.3

Sign up to get free protection for your applications and to get access to all the features.
data/History CHANGED
@@ -1,4 +1,8 @@
1
- v0.4.0
1
+ v0.3.3
2
+ * Fix rake fgraph:setup not creating fgraph.yml config on gem install
3
+ * Update Rdoc
4
+
5
+ v0.3.2
2
6
  * Add FGraph::Client#instance
3
7
  * Handle expired session error in fgraph_logged_in? gracefully
4
8
 
data/README.rdoc CHANGED
@@ -205,9 +205,11 @@ on Facebook server. The trick is you have to catch <tt>FGraph::OAuthError</tt>
205
205
  in <tt>ApplicationController</tt>:
206
206
 
207
207
  rescue_from FGraph::OAuthError do
208
- flash[:notice] = "Your Facebook session has expired, please login again."
209
- reset_session
210
- redirect_to index_url
208
+ # Delete existing invalid cookies
209
+ cookies.delete "fbs_#{FGraph.config['app_id']}"
210
+
211
+ # Redirect to referrer page
212
+ redirect_to request.env['REQUEST_PATH']
211
213
  end
212
214
 
213
215
  == License
data/VERSION.yml CHANGED
@@ -1,5 +1,5 @@
1
1
  ---
2
- :patch: 2
2
+ :patch: 3
3
3
  :major: 0
4
4
  :build:
5
5
  :minor: 3
@@ -4,8 +4,17 @@ namespace :fgraph do
4
4
  desc "Create fgraph.yml configuration file in Rails config folder"
5
5
  task :setup => :environment do
6
6
  fgraph_config = File.join(RAILS_ROOT, "config", "fgraph.yml")
7
+ fgraph_template_dir = File.join(RAILS_ROOT, "vendor", "plugins", "fgraph", "templates")
8
+
9
+ unless File.exists?(fgraph_template_dir)
10
+ fgraph_data_dir = Gem.datadir('fgraph')
11
+ if fgraph_data_dir
12
+ fgraph_template_dir = fgraph_data_dir.split('/')[0..-3].join('/') + '/templates'
13
+ end
14
+ end
15
+
7
16
  unless File.exist?(fgraph_config)
8
- fgraph_config_template = File.join(RAILS_ROOT, "vendor", "plugins", "fgraph", "templates", "fgraph.yml")
17
+ fgraph_config_template = File.join(fgraph_template_dir, "fgraph.yml")
9
18
  FileUtils.cp fgraph_config_template, fgraph_config
10
19
  puts "#{RAILS_ROOT}/config/fgraph.yml created, please update your app_id and app_secret."
11
20
  else
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fgraph
3
3
  version: !ruby/object:Gem::Version
4
- hash: 23
4
+ hash: 21
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 3
9
- - 2
10
- version: 0.3.2
9
+ - 3
10
+ version: 0.3.3
11
11
  platform: ruby
12
12
  authors:
13
13
  - Herryanto Siatono
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2010-07-07 00:00:00 +08:00
18
+ date: 2010-08-20 00:00:00 +08:00
19
19
  default_executable:
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency