GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.

V4Formatter   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 10
Duplicated Lines 100 %

Coupling/Cohesion

Components 0
Dependencies 1

Importance

Changes 0
Metric Value
wmc 1
lcom 0
cbo 1
dl 10
loc 10
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A getContent() 7 7 1

How to fix   Duplicated Code   

Duplicated Code

Duplicate code is one of the most pungent code smells. A rule that is often used is to re-structure code once it is duplicated in three or more places.

Common duplication problems, and corresponding solutions are:

1
<?php
2
/**
3
 * This file is part of the ramsey/uuid-console application
4
 *
5
 * For the full copyright and license information, please view the LICENSE
6
 * file that was distributed with this source code.
7
 *
8
 * @copyright Copyright (c) Ben Ramsey <[email protected]>
9
 * @license http://opensource.org/licenses/MIT MIT
10
 * @link https://packagist.org/packages/ramsey/uuid-console Packagist
11
 * @link https://github.com/ramsey/uuid-console GitHub
12
 */
13
14
namespace Ramsey\Uuid\Console\Util\Formatter;
15
16
use Ramsey\Uuid\Console\Util\UuidFormatter;
17
use Ramsey\Uuid\UuidInterface;
18
use Ramsey\Uuid\Console\Util\UuidContentFormatterInterface;
19
20 View Code Duplication
class V4Formatter implements UuidContentFormatterInterface
21
{
22
    public function getContent(UuidInterface $uuid)
23
    {
24
        return array(
25
            array('', 'content:', substr(chunk_split($uuid->getHex(), 2, ':'), 0, -1)),
26
            array('', '', '(no semantics: random data only)'),
27
        );
28
    }
29
}
30