refactor create