ackwell/ninjabot — pull request #90 by gnustomp (2014-05-29 07:27:53+00:00)
Title: ninjabot: sanitisation, preparation changes

Here's something to mull over.
Warning: this code may look scarily compact.

1. A string can be spliced with `[:n]` even if the string is shorter than length `n`.
2. Using `unicode-escape` to encode the string helpfully stops escape sequences. However, this may not be what some people want. The difference here is that it does not destroy bad escape sequences, but rather stops them from being bad.
3. A lot less code.

If you aren't going to merge this, d23a3a3 should probably be reverted.