The current script contains a bug: missing translations are replaced by the base language. That's alright. However, those base translations get escaped multiple times, because your code processes the same String object multiple times by reference. E.g. "Foo" gets \\\\"Foo\\\\" instead of \\"Foo\\". You can fix this by copying the String values instead of using their references.
The current script contains a bug: missing translations are replaced by the base language. That's alright. However, those base translations get escaped multiple times, because your code processes the same String object multiple times by reference. E.g. "Foo" gets \\\\"Foo\\\\" instead of \\"Foo\\". You can fix this by copying the String values instead of using their references.