refactor run initWith method