Corrects permissions handling errors