change prepare fun