ImagePreviewUrl::getMethod()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 4

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 4
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 0
1
<?php
2
3
namespace JellyBool\Flysystem\Upyun\Plugins;
4
5
use League\Flysystem\Plugin\AbstractPlugin;
6
7
/**
8
 * Class ImagePreviewUrl
9
 * 
10
 * @package JellyBool\Flysystem\Upyun\Plugins
11
 */
12
class ImagePreviewUrl extends AbstractPlugin
13
{
14
    /**
15
     * Get the method name.
16
     *
17
     * @return string
18
     */
19
    public function getMethod()
20
    {
21
        return 'getUrl';
22
    }
23
24
    public function handle($path = null)
25
    {
26
        return $this->filesystem->getAdapter()->getUrl($path);
27
    }
28
}