Lighthouse has a new layout. Prefer the old one? Return to the old layout, and switch back any time from the link at the top of each page.

Jon Leighton's latest activity

Wednesday, October 06 2010
5763 Refactoring JoinDependency and friends was created in Ruby on Rails
  • Jon Leighton
    Jon Leighton created the ticket at 9:34 PM

    Bo Jeanes and I are working to finally try and create a solid patch adding nested has many through association support to Active Record. See #1152 for that.

    Par...

Thursday, September 30 2010
1152 Support for nested has_many :through associations was updated in Ruby on Rails
  • Jon Leighton
    Jon Leighton commented at 5:59 PM

    It's Bo! Greetings from the past! :)

    I have actually been intending to write a patch for this for a while now. Great to see you have moved it forward some. I wi...

Wednesday, August 04 2010
2034 Exceptions in views hard to catch was updated in Ruby on Rails
  • Jon Leighton
    Jon Leighton commented at 10:58 AM

    Here is a workaround for those who are using Rails 2.3. Place in your ApplicationController:

    rescue_from ActionView::TemplateError do |exception|
      rescue_acti...
Friday, October 02 2009
2675 Support for multiparameter attribute assignment on virtual attribute writers was updated in Ruby on Rails
  • Jon Leighton
    Jon Leighton commented at 3:54 PM

    Would be great to get this fixed. In the meantime, I thought I'd drop in and say that I found a very hack solution:

    class Whatever < ActiveRecord::Base
      ...
     ...
Thursday, January 29 2009
1202 Add attributes writer method for an association. was updated in Ruby on Rails
  • Jon Leighton
    Jon Leighton commented at 11:06 PM

    I came across this via the Rails blog post. I'm interested because I have been working on solving a similar problem through a plugin I have called Conductor.

    My...

Monday, January 19 2009
879 Finding the days/weeks/months/years between two dates was updated in Ruby on Rails
  • Jon Leighton
    Jon Leighton commented at 7:31 PM

    Crap, I should really read the formatting help before guessing things. A preview would be nice too. Here are those three pieces of code for readability's sake:

    ...
  • Jon Leighton
    Jon Leighton commented at 7:29 PM

    I think it should return negative values and be clear about this in the documentation. I agree with Dan that's it's a question of perception, but returning an a...

Sunday, December 21 2008
142 belongs_to association not updated when assigning to foreign key was updated in Ruby on Rails
  • Jon Leighton
    Jon Leighton commented at 10:41 AM

    I had a think and a tinker about that, but as far as I can tell, there is no way for a belongs_to association to ask "what associations go through me?". We coul...

  • Jon Leighton
    Jon Leighton commented at 12:38 AM

    Sort of... there are two commit (the one I did before and a new one on top of that) but they should be separate files, which I will attach now. Thanks.

Saturday, December 20 2008
142 belongs_to association not updated when assigning to foreign key was updated in Ruby on Rails
  • Jon Leighton
    Jon Leighton commented at 11:00 PM

    Updated patch to resolve the above issue.