Added an IllegalArgumentException handler.