Ruby on Rails Saturday, July 7, 2012

On 7 July 2012 18:12, David M. <lists@ruby-forum.com> wrote:
> Hassan Schroeder wrote in post #1067817:
>> On Sat, Jul 7, 2012 at 10:02 AM, David M. <lists@ruby-forum.com> wrote:
>>
>>>>> The file handling code I have doesn't seem to function unless it happens
>>>>> after_save, I'm not sure why that is.
>>>>
>>>> Well, since it's a "learning project" maybe that would be a good place
>>>> to start :-)
>>>
>>> Any hints?
>>
>> Start by defining exactly what "doesn't seem to function" means :-)
>>
>> --
>> Hassan Schroeder ------------------------ hassan.schroeder@gmail.com
>> http://about.me/hassanschroeder
>> twitter: @hassan
>
> When outside of after_save, a database entry gets created, but file_data
> doesn't get saved to the hard drive.

You need to do some debugging to see what is going on. Is the save
failing or is it not getting to the save statement for some reason?
Having worked out which of those is happening then do more debugging
to find out why.

Colin

--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en-US.

No comments:

Post a Comment