Passed
Push — master ( da854f...7450e6 )
by Carlos
02:47 queued 57s
created

FetchFile   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 12
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 1

Test Coverage

Coverage 0%

Importance

Changes 1
Bugs 0 Features 1
Metric Value
wmc 2
c 1
b 0
f 1
lcom 1
cbo 1
dl 0
loc 12
ccs 0
cts 8
cp 0
rs 10

2 Methods

Rating   Name   Duplication   Size   Complexity  
A getMethod() 0 4 1
A handle() 0 4 1
1
<?php
2
3
/*
4
 * This file is part of the overtrue/flysystem-qiniu.
5
 * (c) overtrue <[email protected]>
6
 * This source file is subject to the MIT license that is bundled
7
 * with this source code in the file LICENSE.
8
 */
9
10
namespace Overtrue\Flysystem\Qiniu\Plugins;
11
12
use League\Flysystem\Plugin\AbstractPlugin;
13
14
class FetchFile extends AbstractPlugin
15
{
16
    public function getMethod()
17
    {
18
        return 'fetch';
19
    }
20
21
    public function handle($path, $url)
22
    {
23
        return $this->filesystem->getAdapter()->fetch($path, $url);
24
    }
25
}
26