Fixes zero-length regexp replace. See tessel/runtime#107