Environment   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 16
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Test Coverage

Coverage 0%

Importance

Changes 0
Metric Value
dl 0
loc 16
ccs 0
cts 3
cp 0
rs 10
c 0
b 0
f 0
wmc 1
lcom 0
cbo 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A toOptionArray() 0 7 1
1
<?php
2
3
namespace Stockbase\Integration\Model\Config\Source;
4
5
use Magento\Framework\Option\ArrayInterface;
6
7
/**
8
 * Selector source for the Environment configuration option.
9
 */
10
class Environment implements ArrayInterface
11
{
12
    const PRODUCTION = 'production';
13
    const STAGING = 'staging';
14
15
    /**
16
     * @return array
17
     */
18
    public function toOptionArray()
19
    {
20
        return [
21
            ['value' => self::STAGING, 'label' => __('Staging')],
22
            ['value' => self::PRODUCTION, 'label' => __('Production')],
23
        ];
24
    }
25
}
26