add Exception
refactor