Rather than optObj deciding the type of name.  You could just have optName and optWuid.. same number of variables, but clearer.