refactor enter preparing