fix exception being thrown when no arguments are passed