modified checking of existence app