correct enum auto with function (refs #4139)