Created
May 20, 2011 18:10
-
-
Save meltzerj/983446 to your computer and use it in GitHub Desktop.
This file contains hidden or 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 heard | |
| if params[:state] == 'yes' | |
| @heard = true | |
| elsif params[:state] == 'no' | |
| @heard = false | |
| end | |
| respond_to do |format| | |
| if ShowableVideo.find_by_id(params[:showable_video_id]).update_attributes(:heard => @heard) | |
| format.html { redirect_to :back } | |
| format.js | |
| else | |
| format.html { redirect_to :back } | |
| format.js | |
| end | |
| end | |
| end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment