Fix crashes with invalidate Options Menu
Fix null pointer associated with context usage