Code Duplication    Length = 5-5 lines in 2 locations

src/Rauth.php 2 locations

@@ 107-111 (lines=5) @@
104
        $sig = ($method) ? $className . '::' . $method : $className;
105
106
        // Class auths haven't been cached yet
107
        if (!$this->getCache()->has($className)) {
108
            $r = new \ReflectionClass($className);
109
            preg_match_all(self::REGEX, $r->getDocComment(), $matchC);
110
            $this->getCache()->set($className, $this->normalize((array)$matchC));
111
        }
112
113
        // Method auths haven't been cached yet
114
        if (!$this->getCache()->has($sig)) {
@@ 114-118 (lines=5) @@
111
        }
112
113
        // Method auths haven't been cached yet
114
        if (!$this->getCache()->has($sig)) {
115
            $r = new \ReflectionMethod($className, $method);
116
            preg_match_all(self::REGEX, $r->getDocComment(), $matchC);
117
            $this->getCache()->set($sig, $this->normalize((array)$matchC));
118
        }
119
120
        return ($this->getCache()->get($sig) == [])
121
            ? $this->getCache()->get($className)