wrong existence check fixed