fixing bug negating range of characters raises error while deleting items from a non set