Fix a bug preventing creating new notebook when a new noteobok is opened