Completed
Push — master ( 1fe75f...12dabe )
by Song
02:17
created

Timezone   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 13
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 2

Importance

Changes 0
Metric Value
dl 0
loc 13
rs 10
c 0
b 0
f 0
wmc 1
lcom 1
cbo 2

1 Method

Rating   Name   Duplication   Size   Complexity  
A render() 0 8 1
1
<?php
2
3
namespace Encore\Admin\Form\Field;
4
5
use DateTimeZone;
6
7
class Timezone extends Select
8
{
9
    protected $view = 'admin::form.select';
10
11
    public function render()
12
    {
13
        $this->options = collect(DateTimeZone::listIdentifiers(DateTimeZone::ALL))->mapWithKeys(function ($timezone) {
14
            return [$timezone => $timezone];
15
        })->toArray();
16
17
        return parent::render();
0 ignored issues
show
Bug Compatibility introduced by
The expression parent::render(); of type string|Illuminate\View\V...\Contracts\View\Factory adds the type Illuminate\Contracts\View\Factory to the return on line 17 which is incompatible with the return type declared by the interface Illuminate\Contracts\Support\Renderable::render of type string.
Loading history...
18
    }
19
}
20