javascript try catch throw new exception