Code Duplication    Length = 8-8 lines in 2 locations

src/Validation/Execution/JsonApiErrorCollection.php 1 location

@@ 100-107 (lines=8) @@
97
     *
98
     * @return string
99
     */
100
    private function getValidationMessage(ErrorInterface $error): string
101
    {
102
        $context = $error->getMessageContext();
103
        $args    = $context === null ? [] : $context;
104
        $message = $this->getMessageFormatter()->formatMessage($error->getMessageCode(), $args);
105
106
        return $message;
107
    }
108
109
    /**
110
     * @return FormatterInterface

src/Validation/Validator.php 1 location

@@ 560-567 (lines=8) @@
557
     *
558
     * @return string
559
     */
560
    private function getMessage(ErrorInterface $error): string
561
    {
562
        $context = $error->getMessageContext();
563
        $args    = $context === null ? [] : $context;
564
        $message = $this->formatMessage($error->getMessageCode(), $args);
565
566
        return $message;
567
    }
568
569
    /**
570
     * @return array