Merge "Fix NullPointerException on a null Application object"