This way, whenever you save or delete a photo instance, it'll 'touch'
its parent user, and update the updated_at timestamp.
This will require you to upgrade to edge rails, though.
Looking at your attempt, though, I'm not sure this is what you want. Are
you also using the "updated_by" attribute of the photo to save the id of
the user that changed it?
Because the upduser is the same, it doesn't think that the object has really changed, so doesn't update the timestamps.
We had a similar problem where we needed to update the timestamps on the root object of a tree whenever anything in the tree changed. I ended up implementing a touch method on the object, and called that in a before_save hook.