So exactly what was the fix for the invalid argument error on line 334? Having same issue here. Thanks!