annotate app/controllers/tweets_controller.rb @ 37:81f23f5bf85d

There's no i18n here.
author edogawaconan <me@myconan.net>
date Thu, 11 Dec 2014 15:44:51 +0900
parents 03f904c070f7
children 9e03bbbb1d43
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
15
207917e41964 Add tweets~
edogawaconan <me@myconan.net>
parents:
diff changeset
1 class TweetsController < ApplicationController
207917e41964 Add tweets~
edogawaconan <me@myconan.net>
parents:
diff changeset
2 def show
207917e41964 Add tweets~
edogawaconan <me@myconan.net>
parents:
diff changeset
3 @tweets = Tweet.new(params[:id]).timeline
28
03f904c070f7 Basic caching support.
edogawaconan <me@myconan.net>
parents: 25
diff changeset
4
15
207917e41964 Add tweets~
edogawaconan <me@myconan.net>
parents:
diff changeset
5 @user = @tweets.first.user
25
70d70736faee Properly rescue 403 and 404.
edogawaconan <me@myconan.net>
parents: 15
diff changeset
6 rescue Twitter::Error::NotFound
70d70736faee Properly rescue 403 and 404.
edogawaconan <me@myconan.net>
parents: 15
diff changeset
7 head :not_found
70d70736faee Properly rescue 403 and 404.
edogawaconan <me@myconan.net>
parents: 15
diff changeset
8 rescue Twitter::Error::Unauthorized
70d70736faee Properly rescue 403 and 404.
edogawaconan <me@myconan.net>
parents: 15
diff changeset
9 head :forbidden
15
207917e41964 Add tweets~
edogawaconan <me@myconan.net>
parents:
diff changeset
10 end
207917e41964 Add tweets~
edogawaconan <me@myconan.net>
parents:
diff changeset
11 end