Showing 318 of 14,363 total issues
Method __construct
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
$facadeClass,
AuthorizationCheckerInterface $authorizationChecker,
MultiLanguagesChoiceManagerInterface $multiLanguagesChoiceManager,
GroupRepositoryInterface $groupRepository,
BusinessRulesManager $businessRulesManager
- Create a ticketCreate a ticket
Method __construct
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
CsvToReferenceKeywordTransformer $csvToReferenceKeywordTransformer,
ConditionToReferenceKeywordTransformer $conditionToReferenceKeywordTransformer,
KeywordRepositoryInterface $keywordRepository,
RouterInterface $router,
AuthorizationCheckerInterface $authorizationChecker
- Create a ticketCreate a ticket
Method __construct
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
$siteClass,
TranslatorInterface $translator,
TemplateManager $templateManager,
EventSubscriberInterface $webSiteSubscriber,
EventDispatcherInterface $eventDispatcher
- Create a ticketCreate a ticket
Method testBuilder
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
public function testBuilder($creation, $formTimes, $transformerTimes, $subscriberTimes, $dispatcherTimes)
- Create a ticketCreate a ticket
Method checkAddReferencesToEntity
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
protected function checkAddReferencesToEntity($entity, $entityId, array $usedItems, $entityType, $itemRepository)
- Create a ticketCreate a ticket
Method completeRoutePattern
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
protected function completeRoutePattern($parentId = null, $suffix = null, $language, $siteId, array $routePattern)
- Create a ticketCreate a ticket
Method __construct
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
$contentTypeClass,
TranslatorInterface $translator,
array $backOfficeLanguages,
ContentTypeTypeSubscriber $contentTypeTypeSubscriber,
ContentTypeStatusableSubscriber $contentTypeStatusableSubscriber
- Create a ticketCreate a ticket
Method generateNode
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
protected function generateNode($language, $id, $pattern, $parentId, $nodeId)
- Create a ticketCreate a ticket
Method testPreSubmit
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
public function testPreSubmit($developer, $adminPlatform, $data, $nbrAdd, $nbrDelete)
- Create a ticketCreate a ticket
Method __construct
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
WorkflowProfileRepositoryInterface $workflowProfileRepository,
ContentTypeRepositoryInterface $contentTypeRepository,
DataTransformerInterface $workflowProfileCollectionTransformer,
ContextBackOfficeInterface $contextManager,
TranslatorInterface $translator
- Create a ticketCreate a ticket
Function addPreviewLinks
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
protected function addPreviewLinks(FacadeInterface $facade, NodeInterface $node)
{
if ($this->hasGroup(CMSGroupContext::PREVIEW) && $site = $this->siteRepository->findOneBySiteId($node->getSiteId())) {
/** @var SiteAliasInterface $alias */
$encryptedId = $this->encrypter->encrypt($node->getId());
- Read upRead up
- Create a ticketCreate a ticket
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function _submit
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
_submit(event) {
event.preventDefault();
if (this._validForm()) {
let serializeFields = $('form', this.$el).serializeArray();
let oo_internal_link = {};
- Read upRead up
- Create a ticketCreate a ticket
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function UrlPaginateViewMixin
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
let UrlPaginateViewMixin = (superclass) => class extends superclass {
/**
* @inheritDoc
*/
- Read upRead up
- Create a ticketCreate a ticket
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function testSqlExpression
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
testSqlExpression(testedString) {
let isSqlExpression = true
if(this.getBalancedBracketsRegExp().test(testedString)) {
let subTestedString = this.getBalancedBracketsRegExp().exec(testedString);
testedString = testedString.replace(subTestedString[0], '#');
- Read upRead up
- Create a ticketCreate a ticket
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function updateNodeOnSiteAliasUpdate
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
public function updateNodeOnSiteAliasUpdate(SiteEvent $event)
{
$languages = array();
foreach ($event->getOldAliases() as $alias) {
$languages[] = $alias->getLanguage();
- Read upRead up
- Create a ticketCreate a ticket
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function buildView
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
public function buildView(FormView $view, FormInterface $form, array $options)
{
$data = $view->vars['columns']['labels']['data'];
$language = $this->contextManager->getBackOfficeLanguage();
- Read upRead up
- Create a ticketCreate a ticket
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function isInPerimeter
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
public function isInPerimeter($item, PerimeterInterface $perimeter)
{
if ($perimeter->getType() == $this->getType() && is_string($item)) {
foreach ($perimeter->getItems() as $path) {
if (0 === strpos($item, $path)) {
- Read upRead up
- Create a ticketCreate a ticket
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function getBackOfficeLanguage
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
public function getBackOfficeLanguage()
{
$currentLanguage = $this->session->get(self::KEY_LOCALE);
if (!$currentLanguage) {
- Read upRead up
- Create a ticketCreate a ticket
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function addFormType
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
protected function addFormType(FormEvent $event)
{
$form = $event->getForm();
$data = $event->getData();
$event->setData($data);
- Read upRead up
- Create a ticketCreate a ticket
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function getAgglomeratedPerimeter
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
protected function getAgglomeratedPerimeter(UserInterface $user, $entityType)
{
if (false === $this->hasCachedPerimeters($user, $entityType)) {
$cachedPerimeter = $this->perimeterManager->createPerimeter($entityType);
foreach ($user->getGroups() as $group) {
- Read upRead up
- Create a ticketCreate a ticket
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"