]> projects.mako.cc - selectricity-live/blob - app/controllers/site_controller.rb
fixed the string modification function and added support for a titlecase method
[selectricity-live] / app / controllers / site_controller.rb
1 class SiteController < ApplicationController
2   layout 'hc'
3   model :user, :election
4
5   def index
6     if session[:user]
7       session[:user] = User.find(session[:user].id)
8       @current_elections = session[:user].elections.sort do |a,b|
9         b.enddate <=> a.enddate
10       end
11     end
12   end
13
14 end

Benjamin Mako Hill || Want to submit a patch?