modify give function