public function get(string $key = null)
    {
        if (empty($key)) {
            return $this->settings;
        }

        if (\strpos($key, '.') != false) {
            return $this->getNested($key);
        }

        if ($this->has($key)) {
            return $this->settings[$key];
        }

        return null;
    }