@@ 24-35 (lines=12) @@ | ||
21 | /** |
|
22 | * {@inheritdoc} |
|
23 | */ |
|
24 | public static function fixDestination(Uploader $uploader, $original) |
|
25 | { |
|
26 | $path = Uploader::parsePath($original->getClientFilename()); |
|
27 | ||
28 | if (!$uploader->getFilename()) { |
|
29 | $uploader->setFilename($path['filename']); |
|
30 | } |
|
31 | ||
32 | if (!$uploader->getExtension()) { |
|
33 | $uploader->setExtension($path['extension']); |
|
34 | } |
|
35 | } |
|
36 | ||
37 | /** |
|
38 | * {@inheritdoc} |
@@ 23-34 (lines=12) @@ | ||
20 | /** |
|
21 | * {@inheritdoc} |
|
22 | */ |
|
23 | public static function fixDestination(Uploader $uploader, $original) |
|
24 | { |
|
25 | $path = Uploader::parsePath($original['name']); |
|
26 | ||
27 | if (!$uploader->getFilename()) { |
|
28 | $uploader->setFilename($path['filename']); |
|
29 | } |
|
30 | ||
31 | if (!$uploader->getExtension()) { |
|
32 | $uploader->setExtension($path['extension']); |
|
33 | } |
|
34 | } |
|
35 | ||
36 | /** |
|
37 | * {@inheritdoc} |
@@ 23-34 (lines=12) @@ | ||
20 | /** |
|
21 | * {@inheritdoc} |
|
22 | */ |
|
23 | public static function fixDestination(Uploader $uploader, $original) |
|
24 | { |
|
25 | $path = Uploader::parsePath(parse_url($original, PHP_URL_PATH)); |
|
26 | ||
27 | if (!$uploader->getFilename()) { |
|
28 | $uploader->setFilename($path['filename']); |
|
29 | } |
|
30 | ||
31 | if (!$uploader->getExtension()) { |
|
32 | $uploader->setExtension($path['extension']); |
|
33 | } |
|
34 | } |
|
35 | ||
36 | /** |
|
37 | * {@inheritdoc} |