Fix for duplication of characters