Code Duplication    Length = 6-6 lines in 2 locations

src/Surfnet/StepupSelfService/SelfServiceBundle/Assert.php 2 locations

@@ 52-57 (lines=6) @@
49
            $additional = array_diff($givenKeys, $expectedKeys);
50
            $required = array_diff($expectedKeys, $givenKeys);
51
            $message = 'Keys do not match requirements';
52
            if (!empty($additional)) {
53
                $message .= sprintf(
54
                    ', additional keys "%s" found',
55
                    implode('", "', array_diff($givenKeys, $expectedKeys))
56
                );
57
            }
58
            if (!empty($required)) {
59
                $message .= sprintf(
60
                    ', required keys "%s" are missing',
@@ 58-63 (lines=6) @@
55
                    implode('", "', array_diff($givenKeys, $expectedKeys))
56
                );
57
            }
58
            if (!empty($required)) {
59
                $message .= sprintf(
60
                    ', required keys "%s" are missing',
61
                    implode('", "', array_diff($expectedKeys, $givenKeys))
62
                );
63
            }
64
        }
65
        throw new AssertionFailedException($message, 0, $propertyPath, $array);
66
    }