fix #11401: remove deleted tree notes from selected set