Refactor session form