I found the problem, after talk with some other rails developers, I discovered that the Threads was messing up my code I was doing something like that
Thread.new do
#code
end
When I removed the Threads it works without strange errors
質問
I'm generating bills for my application and delivering it via email for customers. When I create a new bill it send the email but, throws the following error:
undefined method `send_bill' for BillMailer:Class
app/models/bill_observer.rb:5:in `after_create'
So, I've run the BillMailer.send_bill from rails consle and it worked fine.
This is driving me crazy, because it sends the email, but throws an error.
Any thought about what it can be?
解決
I found the problem, after talk with some other rails developers, I discovered that the Threads was messing up my code I was doing something like that
Thread.new do
#code
end
When I removed the Threads it works without strange errors