Making pages_images extension compatible with Rails 3.2 (has_many method)