ImApp created in wrong place, causing NPE