Code Duplication    Length = 8-8 lines in 2 locations

src/Handler/ForkHandler.php 1 location

@@ 141-148 (lines=8) @@
138
        $result = $cache->get($key);
139
        $cache->release($key);
140
141
        if (is_object($result) &&
142
            ($result instanceof \Exception
143
                || $result instanceof \Throwable
144
                || $result instanceof \Error
145
            )
146
        ) {
147
            throw $result;
148
        }
149
150
        return $result;
151
    }

src/Handler/PThreadHandler.php 1 location

@@ 96-103 (lines=8) @@
93
    public function getResult()
94
    {
95
        $result = $this->result;
96
        if (is_object($result) &&
97
            ($result instanceof \Exception
98
                || $result instanceof \Throwable
99
                || $result instanceof \Error
100
            )
101
        ) {
102
            throw $result;
103
        }
104
105
        return $result;
106
    }