From 94faaf7d58d32602d3d9b78db1263b469f4ee7b3 Mon Sep 17 00:00:00 2001 From: deepak1556 Date: Sat, 10 Sep 2016 17:50:59 +0530 Subject: [PATCH] provide a default file name for downloads --- atom/browser/api/atom_api_download_item.cc | 2 +- atom/browser/atom_download_manager_delegate.cc | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/atom/browser/api/atom_api_download_item.cc b/atom/browser/api/atom_api_download_item.cc index d11e5a3add72..240444d1ee3d 100644 --- a/atom/browser/api/atom_api_download_item.cc +++ b/atom/browser/api/atom_api_download_item.cc @@ -135,7 +135,7 @@ std::string DownloadItem::GetFilename() const { std::string(), download_item_->GetSuggestedFilename(), GetMimeType(), - std::string()).LossyDisplayName()); + "download").LossyDisplayName()); } std::string DownloadItem::GetContentDisposition() const { diff --git a/atom/browser/atom_download_manager_delegate.cc b/atom/browser/atom_download_manager_delegate.cc index 7f5605052a02..0213216697a1 100644 --- a/atom/browser/atom_download_manager_delegate.cc +++ b/atom/browser/atom_download_manager_delegate.cc @@ -60,7 +60,7 @@ void AtomDownloadManagerDelegate::CreateDownloadPath( std::string(), suggested_filename, mime_type, - std::string()); + "download"); if (!base::PathExists(default_download_path)) base::CreateDirectory(default_download_path);