Never cache get file requests for Google Drive as the downloadUrl needs to be up to date.

This commit is contained in:
John Maguire 2012-10-23 16:12:15 +02:00
parent c8312b7cdf
commit 313ca6932c
1 changed files with 3 additions and 0 deletions

View File

@ -164,6 +164,9 @@ GetFileResponse* Client::GetFile(const QString& file_id) {
QNetworkRequest request = QNetworkRequest(url);
AddAuthorizationHeader(&request);
// Never cache these requests as we will get out of date download URLs.
request.setAttribute(
QNetworkRequest::CacheLoadControlAttribute, QNetworkRequest::AlwaysNetwork);
QNetworkReply* reply = network_->get(request);
NewClosure(reply, SIGNAL(finished()),