bug fix
New function: toParam