Code Duplication    Length = 9-9 lines in 2 locations

src/Http/BaseController.php 2 locations

@@ 382-390 (lines=9) @@
379
     *
380
     * @return JsonApiValidatorInterface
381
     */
382
    protected static function createOnCreateValidator(ContainerInterface $container): JsonApiValidatorInterface
383
    {
384
        assert(
385
            empty(static::ON_CREATE_VALIDATION_RULES_SET_CLASS) === false,
386
            'Validation rules set should be defined for class ' . static::class . '.'
387
        );
388
389
        return static::createJsonApiValidator($container, static::ON_CREATE_VALIDATION_RULES_SET_CLASS);
390
    }
391
392
    /**
393
     * @param ContainerInterface $container
@@ 397-405 (lines=9) @@
394
     *
395
     * @return JsonApiValidatorInterface
396
     */
397
    protected static function createOnUpdateValidator(ContainerInterface $container): JsonApiValidatorInterface
398
    {
399
        assert(
400
            empty(static::ON_UPDATE_VALIDATION_RULES_SET_CLASS) === false,
401
            'Validation rules set should be defined for class ' . static::class . '.'
402
        );
403
404
        return static::createJsonApiValidator($container, static::ON_UPDATE_VALIDATION_RULES_SET_CLASS);
405
    }
406
407
    /**
408
     * @param ContainerInterface $container