app/controllers/projects_controller.rb
#
# Loads project if params[:id] is given. This method should be called in before_filter.
#

Loads project if params[:id] is given. This method should be called in before_filter.
Loads project if params [ : id ] is given . This method should be called in before_filter .
def load_project
    @project = Project.find( params[:id] ) if params[:id]
  rescue ActiveRecord::RecordNotFound
    flash[:notice] = "No such project"
    redirect_to :action => :index    
  end
def load_project @project = Project . find ( params [ :id ] ) if params [ :id ] rescue ActiveRecord :: RecordNotFound flash [ :notice ] = "No such project" redirect_to :action => :index end
Loads project if params[:id] is given.
Loads project if params [ : id ] is given .