Fixed encoding foo, closes #1