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.
Completed
Push — 0.x ( 9442bf...01fcfa )
by Henrik
03:08 queued 03:04
created

functions.php ➔ bernard_decode_class_string()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 1
eloc 2
c 1
b 0
f 0
nc 1
nop 1
dl 0
loc 4
rs 10
1
<?php
2
3
use Bernard\Message;
4
5
/**
6
 * @param  string $className
7
 * @return string
8
 */
9
function bernard_encode_class_name($className)
10
{
11
    return str_replace('\\', ':', $className);
12
}
13
14
/**
15
 * @param  string $classString
16
 * @return string
17
 */
18
function bernard_decode_class_string($classString)
19
{
20
    return str_replace(':', '\\', $classString);
21
}
22
23
function bernard_force_property_value($object, $property, $value)
24
{
25
    $property = new \ReflectionProperty($object, $property);
26
    $property->setAccessible(true);
27
    $property->setValue($object, $value);
28
}
29
30
function bernard_guess_queue(Message $message)
31
{
32
    return trim(strtolower(preg_replace('/[A-Z]/', '-\\0', $message->getName())), '-');
33
}
34