Transforming monkeypatch on ActiveRecord::Base into a concern, fixing delete for habtm, adding singletons (models which don't get duplicated)