Check for write permissions before attempting to download the file