updated showHome function