2011-04-19 1 views

Répondre

0

Bien sûr, vous pouvez!

Ecrivez un gestionnaire d'erreur pour l'exception MongoId Sinatra:

error Mongoid::Errors::DocumentNotFound do 
    #pass the id's to the view 
    haml :mongoiderror, :locals => { :ids => request.env['sinatra.error'].identifiers } 
end 
Questions connexes