Add Restrict function