fix from https://github.com/specle/tolk/