From 6796d15d8b782e1e221e635f54332fdf9bfd5ccc Mon Sep 17 00:00:00 2001
From: Ronan Dowling <ronan@getpantheon.com>
Date: Wed, 3 Feb 2016 20:58:38 -0600
Subject: [PATCH] Prepare file directory before writing backup

---
 src/Destination/DrupalDirectoryDestination.php | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/Destination/DrupalDirectoryDestination.php b/src/Destination/DrupalDirectoryDestination.php
index ad06658..97d0c43 100644
--- a/src/Destination/DrupalDirectoryDestination.php
+++ b/src/Destination/DrupalDirectoryDestination.php
@@ -55,9 +55,9 @@ class DrupalDirectoryDestination extends DirectoryDestination {
           ['%dir' => $dir]
         );
       }
-      if (!PrivateStream::basePath() || !file_prepare_directory($dir, FILE_CREATE_DIRECTORY && FILE_MODIFY_PERMISSIONS)) {
+      if (!file_prepare_directory($dir, FILE_CREATE_DIRECTORY && FILE_MODIFY_PERMISSIONS)) {
         throw new BackupMigrateException(
-          "The backup file could not be saved to '%dir' because the directory could not be created or cannot be written to. Please make sure your private files directory is configured and writable by the web server.",
+          "The backup file could not be saved to '%dir' because the directory could not be created or cannot be written to. Please make sure your private files directory is writable by the web server.",
           ['%dir' => $dir]
         );
       }
-- 
GitLab