Class: MyTimeline::TwitterController
- Inherits:
-
ApplicationController
- Object
- ApplicationController
- MyTimeline::TwitterController
- Defined in:
- app/controllers/my_timeline/twitter_controller.rb
Instance Method Summary collapse
Instance Method Details
#new ⇒ Object
4 5 6 7 8 |
# File 'app/controllers/my_timeline/twitter_controller.rb', line 4 def new @user.settings(:twitter).user_name = params[:user_name] @user.save! redirect_to control_panel_path, notice: "Twitter added!" end |
#scrape ⇒ Object
10 11 12 13 |
# File 'app/controllers/my_timeline/twitter_controller.rb', line 10 def scrape scrapey = MyTimeline::Twitter::TweetScraper.new(@user).scrape redirect_to :back, notice: "Added #{scrapey} tweets." end |