move text message to exception class