1. 19 Jan, 2015 1 commit
    • Create Failing Test · ed7793d4
      Restoring polymorphic has_one relationships errored because paranoia was
      not correctly looking up the foreign_key.
      
      Output from failing test -
      
      ActiveRecord::StatementInvalid: SQLite3::SQLException: no such column: parent_model_id: SELECT  "polymorphic_models".* FROM "polymorphic_models" WHERE ("polymorphic_models"."deleted_at" IS NOT NULL) AND (parent_model_id)  ORDER BY "polymorphic_models"."id" ASC LIMIT 1
      
      The test sets up a PolymorphicModel, which has_many parents. The
      ParentModel then has a has_one relationship with PolymorphicModel. When
      restoring, the foreign key is set as - `self.class.name.to_s.underscore_id`
      which will be parent_model_id, instead of the :as option.
      Patrick Koperwas committed
  2. 18 Jan, 2015 5 commits
  3. 09 Jan, 2015 1 commit
  4. 23 Dec, 2014 1 commit
  5. 17 Dec, 2014 2 commits
  6. 03 Dec, 2014 3 commits
  7. 28 Nov, 2014 3 commits
  8. 27 Nov, 2014 2 commits
  9. 26 Nov, 2014 4 commits
  10. 23 Nov, 2014 1 commit
  11. 21 Nov, 2014 1 commit
  12. 19 Nov, 2014 1 commit
  13. 13 Nov, 2014 1 commit
  14. 23 Sep, 2014 2 commits
  15. 19 Sep, 2014 1 commit
  16. 18 Sep, 2014 1 commit
  17. 16 Sep, 2014 2 commits
  18. 08 Sep, 2014 1 commit
  19. 04 Sep, 2014 2 commits
  20. 29 Aug, 2014 1 commit
  21. 28 Aug, 2014 3 commits
  22. 26 Aug, 2014 1 commit