Code Duplication    Length = 25-25 lines in 2 locations

src/Arrayy.php 2 locations

@@ 3509-3533 (lines=25) @@
3506
3507
                /** @noinspection PhpParameterByRefIsNotUsedAsReferenceInspection */
3508
                foreach ($this->getGeneratorByReference() as $key => &$value) {
3509
                    if (
3510
                        (
3511
                            $is_array_tmp === false
3512
                            &&
3513
                            $strict === true
3514
                            &&
3515
                            $search_values === $value
3516
                        )
3517
                        ||
3518
                        (
3519
                            $is_array_tmp === false
3520
                            &&
3521
                            $strict === false
3522
                            &&
3523
                            $search_values == $value
3524
                        )
3525
                        ||
3526
                        (
3527
                            $is_array_tmp === true
3528
                            &&
3529
                            \in_array($value, $search_values, $strict)
3530
                        )
3531
                    ) {
3532
                        yield $key;
3533
                    }
3534
                }
3535
            };
3536
        }
@@ 6246-6270 (lines=25) @@
6243
            $is_array_tmp = \is_array($search_values);
6244
6245
            foreach ($input as $key => $value) {
6246
                if (
6247
                    (
6248
                        $is_array_tmp === false
6249
                        &&
6250
                        $strict === true
6251
                        &&
6252
                        $search_values === $value
6253
                    )
6254
                    ||
6255
                    (
6256
                        $is_array_tmp === false
6257
                        &&
6258
                        $strict === false
6259
                        &&
6260
                        $search_values == $value
6261
                    )
6262
                    ||
6263
                    (
6264
                        $is_array_tmp === true
6265
                        &&
6266
                        \in_array($value, $search_values, $strict)
6267
                    )
6268
                ) {
6269
                    $keys[] = $key;
6270
                }
6271
6272
                // check if recursive is needed
6273
                if (\is_array($value) === true) {