renamed the exception to avoid namespace collisions
case classes don't require "new"
clean-up and code re-arrangement