This class seems to be duplicated in your project.
Duplicated code is one of the most pungent code smells. If you need to duplicate
the same code in three or more different places, we strongly encourage you to
look into extracting the code into a single class or operation.
You can also find more detailed suggestions in the “Code” section of your repository.
Loading history...
14
{
15
public function getInfo($app, $key, $data)
16
{
17
$result = [];
18
19
$class = $this->ns . $app . '\\' . $data;
20
21
if (is_subclass_of($class, 'OSC\OM\Modules\\' . $this->code . 'Interface')) {
Due to PHP Bug #53727, is_subclass_of might return inconsistent results on some PHP versions if 'OSC\\OM\\Modules\\' . $this->code . 'Interface' can be an interface. If so, you could instead use ReflectionClass::implementsInterface.
Duplicated code is one of the most pungent code smells. If you need to duplicate the same code in three or more different places, we strongly encourage you to look into extracting the code into a single class or operation.
You can also find more detailed suggestions in the “Code” section of your repository.