function hasModifier(e, modifier) {
        return !!e[modifier];
    }
This is used to minimize the edits by removing changes that appear on the edges of the range which are identical
to the current text.

The reason this was introduced is to allow better selection tracking of the current cursor and solve
bug #15108. There the cursor was jumping since the tracked selection was in the middle of the range edit
and was lost.