From 85394a9e9e1d46a16a47d2e5b80dc7635cd041c8 Mon Sep 17 00:00:00 2001 From: James Rhodes Date: Thu, 3 Apr 2014 09:21:35 -0700 Subject: [PATCH] Set name parameter when saving file via Drydock Summary: This sets the name parameter when Drydock uploads a file so that the storage engine picks it up correctly. Test Plan: N/A Reviewers: epriestley, #blessed_reviewers Reviewed By: epriestley, #blessed_reviewers Subscribers: epriestley, Korvin Differential Revision: https://secure.phabricator.com/D8673 --- .../interface/filesystem/DrydockSFTPFilesystemInterface.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/applications/drydock/interface/filesystem/DrydockSFTPFilesystemInterface.php b/src/applications/drydock/interface/filesystem/DrydockSFTPFilesystemInterface.php index 3a5803871e..bffe85144b 100644 --- a/src/applications/drydock/interface/filesystem/DrydockSFTPFilesystemInterface.php +++ b/src/applications/drydock/interface/filesystem/DrydockSFTPFilesystemInterface.php @@ -46,7 +46,9 @@ final class DrydockSFTPFilesystemInterface extends DrydockFilesystemInterface { public function saveFile($path, $name) { $data = $this->readFile($path); - $file = PhabricatorFile::newFromFileData($data); + $file = PhabricatorFile::newFromFileData( + $data, + array('name' => $name)); $file->setName($name); $file->save(); return $file;