fixes permissions