I think you need a null check here. `getPageManager(adaptable)` could return null.