fixing some permissions issues