Fixing the class structure for models. Added ActiveRecord class