Skip to content
This repository has been archived by the owner on Oct 3, 2019. It is now read-only.

Commit

Permalink
Use the asset pipeline to load the JavaScript.
Browse files Browse the repository at this point in the history
  • Loading branch information
jimmycuadra committed Apr 26, 2013
1 parent 8201706 commit d1dd2ab
Show file tree
Hide file tree
Showing 9 changed files with 5 additions and 20 deletions.
11 changes: 1 addition & 10 deletions lib/facebook_stub.rb
@@ -1,5 +1,5 @@
require "facebook_stub/version"
require 'facebook_stub/rails/action_view_helper'
require "facebook_stub/engine"

module FacebookStub

Expand Down Expand Up @@ -45,15 +45,6 @@ def info
def invalid!
@info = {}
end

def javascript
@javascript ||= File.read File.expand_path('../../bin/facebook-stub.js', __FILE__)
end

end

FacebookStub.reset!

if defined?(ActionView::Base)
ActionView::Base.send(:include, FacebookStub::Rails::ActionViewHelper)
end
4 changes: 4 additions & 0 deletions lib/facebook_stub/engine.rb
@@ -0,0 +1,4 @@
module FacebookStub
class Engine < Rails::Engine
end
end
10 changes: 0 additions & 10 deletions lib/facebook_stub/rails/action_view_helper.rb

This file was deleted.

File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 comments on commit d1dd2ab

Please sign in to comment.