I am playing with Rails 3.1.1 and made a simple blog app.
I created a unique index on a field and when I submit a new post, it
throws an exception if the field is not unique. I've added a rescue, but
it's not doing anything? What am I doing wrong.
def create
@post = Post.new(params[:pos
Well you can specify a default page / controller action to perform for
unmatched routes as well...so if the route doesn't exist it shows a much
user friendly page instead of the rails error message
Thanks & Regards,
Dhruva Sagar.
On Mon, Apr 26, 2010 at 13:52, Tom Mac wrote:
> Hi
> I have co
Hi
I have controller edit action like
def edit
begin
@user = User.find(params[:id])
rescue ActiveRecord::RecordNotFound
logger.warn "User with id #{current_user.id} tried to edit user with
id #{params[:id]}"
render :file => "#{RAILS_ROOT}/public/404.html"
else
---
en
green threads since I'm using JRuby.
I'm unsure how to handle exceptions in the background thread. I'd like
to pass it to Rails' exception handling mechanism so that it is dealt
with in the same way as exceptions that occur during the normal
request-response cycle (except for r
I am utterly unable to control how exceptions are handled in my
application and it's driving me nuts
The idea is simple. I have a SOAP handler like this.
class RtiController < ApplicationController
begin
wsdl_service_name 'Rti'
web_service_scaffold :invoke
web_service_api RtiA
5 matches
Mail list logo