fixed some permissions problems