Code Duplication    Length = 7-7 lines in 2 locations

core/EE_Registry.core.php 2 locations

@@ 610-616 (lines=7) @@
607
        // $this->_cache_on is toggled during the recursive loading that can occur with dependency injection
608
        // $cache is controlled by individual calls to separate Registry loader methods like load_class()
609
        // $load_only is also controlled by individual calls to separate Registry loader methods like load_file()
610
        if ($this->_cache_on && $cache && ! $load_only) {
611
            // return object if it's already cached
612
            $cached_class = $this->_get_cached_class($class_name, $addon);
613
            if ($cached_class !== null) {
614
                return $cached_class;
615
            }
616
        }
617
        // instantiate the requested object
618
        $class_obj = $this->_create_object($class_name, $arguments, $addon, $from_db);
619
        if ($this->_cache_on && $cache) {
@@ 674-680 (lines=7) @@
671
        // $this->_cache_on is toggled during the recursive loading that can occur with dependency injection
672
        // $cache is controlled by individual calls to separate Registry loader methods like load_class()
673
        // $load_only is also controlled by individual calls to separate Registry loader methods like load_file()
674
        if ($this->_cache_on && $cache && ! $load_only) {
675
            // return object if it's already cached
676
            $cached_class = $this->_get_cached_class($class_name, $class_prefix);
677
            if ($cached_class !== null) {
678
                return $cached_class;
679
            }
680
        }
681
        // if the class doesn't already exist.. then we need to try and find the file and load it
682
        if ( ! $class_exists) {
683
            // get full path to file