more refactoring for Card model