public function has($sec, $key = null) { if (!$this->hasSection($sec)) { return false; } if (null !== $key && isset($this->sections[$sec][$key])) { return true; } return false; }