change permissions on refresh