Created
June 17, 2014 13:16
-
-
Save almaron/7baa1b62611a9dfa6b86 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def get_topic | |
@topic = ForumTopic.find(params[:id]) | |
unless @topic | |
respond_to do |format| | |
format.html { redirect_to forum_path(params[:forum_id]) } | |
format.json { render json: {redirect: forum_path(params[:forum_id])}, status: 500 } | |
end | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment