Fixed dialog NPE