@@ -5,8 +5,6 @@ |
||
| 5 | 5 | use phpbu\App\Result; |
| 6 | 6 | use phpbu\App\Backup\Sync; |
| 7 | 7 | use phpbu\App\Backup\Target; |
| 8 | -use phpbu\App\Util\Arr; |
|
| 9 | -use phpbu\App\Util\Str; |
|
| 10 | 8 | |
| 11 | 9 | /** |
| 12 | 10 | * Amazon S3 Sync |
@@ -68,9 +68,9 @@ |
||
| 68 | 68 | public function getUploadPath(Target $target) |
| 69 | 69 | { |
| 70 | 70 | return 's3://' . $this->bucket |
| 71 | - . (substr($this->path, 0, 1) == '/' ? '' : '/') |
|
| 72 | - . $this->path |
|
| 73 | - . (substr($this->path, -1, 1) == '/' ? '' : '/') |
|
| 74 | - . $target->getFilename(); |
|
| 71 | + . (substr($this->path, 0, 1) == '/' ? '' : '/') |
|
| 72 | + . $this->path |
|
| 73 | + . (substr($this->path, -1, 1) == '/' ? '' : '/') |
|
| 74 | + . $target->getFilename(); |
|
| 75 | 75 | } |
| 76 | 76 | } |
@@ -47,7 +47,7 @@ |
||
| 47 | 47 | $s3->registerStreamWrapper(); |
| 48 | 48 | $stream = fopen($targetPath, 'w'); |
| 49 | 49 | $source = fopen($sourcePath, 'r'); |
| 50 | - while(!feof($source)) { |
|
| 50 | + while (!feof($source)) { |
|
| 51 | 51 | fwrite($stream, fread($source, 4096)); |
| 52 | 52 | } |
| 53 | 53 | fclose($stream); |