Added try/catch statement for invalid parameter exceptions thrown from the guard