small cleanup to parameter parsing