fix for invalid arg crash