NOJIRA encoding helper now returns values as well as changing by reference