Code Duplication    Length = 8-8 lines in 2 locations

src/Psecio/Invoke/MatchInstance.php 1 location

@@ 47-54 (lines=8) @@
44
	 * @param string $key Key to locate [optional]
45
	 * @return mixed Either entire config or key is found
46
	 */
47
	public function getConfig($key = null)
48
	{
49
		if ($key !== null) {
50
			return (isset($this->config[$key])) ? $this->config[$key] : null;
51
		} else {
52
			return $this->config;
53
		}
54
	}
55
56
	/**
57
	 * Get the current formatted error message

src/Psecio/Invoke/RouteContainer.php 1 location

@@ 44-51 (lines=8) @@
41
     *
42
     * @return array Configuration set
43
     */
44
    public function getConfig($name = null)
45
    {
46
        if ($name !== null) {
47
            return (isset($this->config[$name])) ? $this->config[$name] : null;
48
        } else {
49
            return $this->config;
50
        }
51
    }
52
53
    /**
54
     * Get the current route instance