**Blender Version**
Broken: version: 2.83 (sub 13), branch: master, commit date: 2020-04-11 15:16, hash: `rB85de07e64c96`
Worked: 2.79
**Short description of error**
Switching to a different collection when an object is still in local view in one collection is behaving unexpectedly.
**Exact steps for others to reproduce the error**
1. Open the default scene and add a sphere then move it to a new collection.
2. In the first collection, select the cube and go into local view and switch to the second collection by pressing 2
In the outliner that the second collection is active but you can see the cube still in the viewport. You can go in an out of various modes but can't do selection, transformation or any other operations. Basically the viewport is somewhat frozen. If you exit local view now, the second collection in shown.
In blender 2.79, you couldn't switch layers if an object was in local view.