fix #1: `escape()` fails with non string types