http://www.bbc.com/future/story/20160307-why-does-walking-through-doorways-make-us-forget
The Doorway Effect occurs when our attention moves between levels, and it reflects the reliance of our memories – even memories for what we were about to do – on the environment we’re in.