changed to unix line endings
escape method now excepts arrays