Always encode given string before passing it to admesh

Fixes #1