added granting to script