| Conditions | 3 |
| Paths | 3 |
| Total Lines | 13 |
| Code Lines | 7 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 0 |
| CRAP Score | 12 |
| Changes | 0 | ||
| 1 | <?php |
||
| 32 | protected function addStorageInstances(array $dataStorages) : void |
||
| 33 | { |
||
| 34 | foreach ($dataStorages as $instance) { |
||
| 35 | if ($instance instanceof StorageInterface) { |
||
| 36 | $storageClassFullName = get_class($instance); |
||
| 37 | $classNamespacePath = explode('\\', $storageClassFullName); |
||
| 38 | |||
| 39 | $storageClass = array_pop($classNamespacePath); |
||
| 40 | |||
| 41 | $this->dataStorages[$storageClass] = $instance; |
||
| 42 | } |
||
| 43 | } |
||
| 44 | } |
||
| 45 | |||
| 62 |