Sha256: 8c9de3fdd0096641d133747155ae57180e20a200d089de572f98c6c3fb7e6077
Contents?: true
Size: 345 Bytes
Versions: 32
Compression:
Stored size: 345 Bytes
Contents
module Lentil class LikeVotesController < Lentil::ApplicationController def tally image = Image.find(params[:image_id]) like_vote = LikeVote.new(:image => image) if like_vote.save session[:liked_images] ||= [] session[:liked_images] << params[:image_id] end redirect_to :back end end end
Version data entries
32 entries across 32 versions & 1 rubygems