src/Screen/Builder.php
private function getValue(string $key, $value = null)
    {
        if (! is_null($this->language)) {
            $key = $this->language.'.'.$key;
        }

        if (! is_null($this->prefix)) {
            $key = $this->prefix.'.'.$key;
        }

        $data = $this->data->getContent($key);

        // default value
        if (is_null($data)) {
            return $value;
        }

        if ($value instanceof \Closure) {
            return $value($data, $this->data);
        }

        return $data;
    }
private function getValue(string $key, $value = null)
    {
        if (! is_null($this->language)) {
            $key = $this->language.'.'.$key;
        }

        if (! is_null($this->prefix)) {
            $key = $this->prefix.'.'.$key;
        }

        $data = $this->data->getContent($key);

        // default value
        if (is_null($data)) {
            return $value;
        }

        if ($value instanceof \Closure) {
            return $value($data, $this->data);
        }

        return $data;
    }
private function getValue ( string $ key , $ value = null ) { if ( ! is_null ( $ this -> language ) ) { $ key = $ this -> language . '.' . $ key ; } if ( ! is_null ( $ this -> prefix ) ) { $ key = $ this -> prefix . '.' . $ key ; } $ data = $ this -> data -> getContent ( $ key ) ; // default value if ( is_null ( $ data ) ) { return $ value ; } if ( $ value instanceof \ Closure ) { return $ value ( $ data , $ this -> data ) ; } return $ data ; }
Gets value of Repository.

@param string     $key
@param mixed|null $value

@return mixed
Gets value of Repository .