fixed wrong grant and dir