Merge "Safe check so we don't move cursor beyond possible pos scope." into nyc-dev