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.

SetEntityAttributes   A
last analyzed

Complexity

Total Complexity 3

Size/Duplication

Total Lines 17
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 6
c 1
b 0
f 0
dl 0
loc 17
rs 10
wmc 3

1 Method

Rating   Name   Duplication   Size   Complexity  
A setAttributes() 0 9 3
1
<?php
2
3
namespace Soheilrt\AdobeConnectClient\Client\Helpers;
4
5
/**
6
 * Set object attributes.
7
 */
8
abstract class SetEntityAttributes
9
{
10
    /**
11
     * Iterate attributes and call the set method from object.
12
     *
13
     * @param mixed $object
14
     * @param mixed $attributes
15
     */
16
    public static function setAttributes(&$object, $attributes)
17
    {
18
        foreach ($attributes as $attr => $value) {
19
            if (is_array($value)) {
20
                static::setAttributes($object, $value);
21
                continue;
22
            }
23
24
            $object->$attr = $value;
25
        }
26
    }
27
}
28