Code Duplication    Length = 9-9 lines in 2 locations

src/League/ServiceServiceProvider.php 1 location

@@ 107-115 (lines=9) @@
104
     *
105
     * @return \Closure
106
     */
107
    private function createFactoryFactory(ServiceDefinition $definition)
108
    {
109
        return function () use ($definition) {
110
            $className = $definition->getClass();
111
            $factory   = new $className();
112
113
            return $factory(...$this->resolveArguments($definition->getArguments()));
114
        };
115
    }
116
117
    /**
118
     * @param array $arguments

src/Pimple/PimpleContainerAdapter.php 1 location

@@ 97-105 (lines=9) @@
94
     *
95
     * @return Closure
96
     */
97
    private function createFactoryFactory(ServiceDefinition $definition)
98
    {
99
        return function () use ($definition) {
100
            $className = $definition->getClass();
101
            $factory   = new $className();
102
103
            return $factory(...$this->resolveArguments($definition->getArguments()));
104
        };
105
    }
106
107
    /**
108
     * @param ServiceDefinition $definition