I found a solution. Add either or both of these lines to your wp-config.php file (as I’m not sure which one fixed the problem, maybe it was both together).
define(‘UPLOADS’, ‘/yourblog/wp-content/uploads’);
define(‘WP_CONTENT_URL’, ‘https://yourblog.com/wp-content’);
Obviously replace ‘yourblog’ with your blog name.
It will bypass the the directory it can’t write to and creates a new directory which it can write to.
Hope it works for you too.