The class ContentController has 12 public methods. Consider refactoring ContentController to keep number of public methods under 10. Open
class ContentController extends BaseController
{
use ListStatus;
/**
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
TooManyPublicMethods
Since: 0.1
A class with too many public methods is probably a good suspect for refactoring, in order to reduce its complexity and find a way to have more fine grained objects.
By default it ignores methods starting with 'get' or 'set'.
Example
Source https://phpmd.org/rules/codesize.html#toomanypublicmethods
The class ContentController has an overall complexity of 50 which is very high. The configured complexity threshold is 50. Open
class ContentController extends BaseController
{
use ListStatus;
/**
- Create a ticketCreate a ticket
- Exclude checks
File ContentController.php
has 304 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
namespace OpenOrchestra\ApiBundle\Controller;
use OpenOrchestra\ApiBundle\Controller\ControllerTrait\ListStatus;
- Create a ticketCreate a ticket
Method duplicateAction
has 26 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function duplicateAction(Request $request)
{
$format = $request->get('_format', 'json');
$facade = $this->get('jms_serializer')->deserialize(
$request->getContent(),
- Create a ticketCreate a ticket
The class ContentController has a coupling between objects value of 17. Consider to reduce the number of dependencies under 13. Open
class ContentController extends BaseController
{
use ListStatus;
/**
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
CouplingBetweenObjects
Since: 1.1.0
A class with too many dependencies has negative impacts on several quality aspects of a class. This includes quality criteria like stability, maintainability and understandability
Example
class Foo {
/**
* @var \foo\bar\X
*/
private $x = null;
/**
* @var \foo\bar\Y
*/
private $y = null;
/**
* @var \foo\bar\Z
*/
private $z = null;
public function setFoo(\Foo $foo) {}
public function setBar(\Bar $bar) {}
public function setBaz(\Baz $baz) {}
/**
* @return \SplObjectStorage
* @throws \OutOfRangeException
* @throws \InvalidArgumentException
* @throws \ErrorException
*/
public function process(\Iterator $it) {}
// ...
}
Source https://phpmd.org/rules/design.html#couplingbetweenobjects
Avoid using static access to class '\OpenOrchestra\Pagination\Configuration\PaginateFinderConfiguration' in method 'listAction'. Open
$configuration = PaginateFinderConfiguration::generateFromRequest($request, $mapping);
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
StaticAccess
Since: 1.4.0
Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.
Example
class Foo
{
public function bar()
{
Bar::baz();
}
}
Source https://phpmd.org/rules/cleancode.html#staticaccess
Expected @param annotation for language
to be before the @param annotation for version
Open
* @param string $version
- Create a ticketCreate a ticket
- Exclude checks
@throws annotation of duplicateAction
has suspicious class type \OpenOrchestra\ApiBundle\Exceptions\HttpException\ContentTypeNotAllowedException,
which does not extend Error/Exception Open
public function duplicateAction(Request $request)
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$content = $this->get('open_orchestra_api.transformer_manager')->reverseTransform('content', $facade);
- Create a ticketCreate a ticket
- Exclude checks
Return type of newVersionAction()
is undeclared type \Symfony\Component\HttpFoundation\Response
Open
public function newVersionAction(Request $request, $contentId, $language, $originalVersion)
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$facade = $this->get('jms_serializer')->deserialize(
- Create a ticketCreate a ticket
- Exclude checks
Return type of showAction()
is undeclared type \OpenOrchestra\BaseApi\Facade\FacadeInterface
Open
public function showAction($contentId, $language, $version)
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
if (!$this->get('open_orchestra_backoffice.business_rules_manager')->isGranted(ContentTypeStrategy::READ_LIST, $contentType)) {
- Create a ticketCreate a ticket
- Exclude checks
Call to method __construct
from undeclared class \OpenOrchestra\ModelInterface\Event\ContentEvent
Open
$this->dispatchEvent(ContentEvents::CONTENT_DUPLICATE, new ContentEvent($duplicateContent));
- Create a ticketCreate a ticket
- Exclude checks
Return type of deleteContentVersionsAction()
is undeclared type \Symfony\Component\HttpFoundation\Response
Open
public function deleteContentVersionsAction(Request $request)
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::getParameter
Open
$this->getParameter('open_orchestra_api.facade.content_collection.class'),
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$site = $this->get('open_orchestra_model.repository.site')->findOneBySiteId($siteId);
- Create a ticketCreate a ticket
- Exclude checks
Reference to constant CONTENT_UPDATE
from undeclared class \OpenOrchestra\ModelInterface\ContentEvents
Open
array(ContentEvents::CONTENT_CREATION, ContentEvents::CONTENT_UPDATE),
- Create a ticketCreate a ticket
- Exclude checks
Call to method get
from undeclared class \Symfony\Component\HttpFoundation\Request
Open
$request->get('_format', 'json')
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::dispatchEvent
Open
$this->dispatchEvent(ContentEvents::CONTENT_DUPLICATE, new ContentEvent($newContent));
- Create a ticketCreate a ticket
- Exclude checks
Possibly zero references to use statement for classlike/namespace Api
(\OpenOrchestra\BaseApiBundle\Controller\Annotation)
Open
use OpenOrchestra\BaseApiBundle\Controller\Annotation as Api;
- Create a ticketCreate a ticket
- Exclude checks
Argument 3 (version)
is string
but \OpenOrchestra\ApiBundle\Controller\ContentController::findOneContent()
takes int|null
defined at /code/ApiBundle/Controller/ContentController.php:490
Open
$content = $this->findOneContent($contentId, $language, $version);
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$contents = $this->get('open_orchestra_api.transformer_manager')->reverseTransform('content_collection', $facade);
- Create a ticketCreate a ticket
- Exclude checks
Saw a token Phan may have failed to parse after '* @throws ContentTypeNotAllowedException,':
after ContentTypeNotAllowedException,
saw ','
Open
* @throws ContentTypeNotAllowedException,
- Create a ticketCreate a ticket
- Exclude checks
Reference to constant CONTENT_DUPLICATE
from undeclared class \OpenOrchestra\ModelInterface\ContentEvents
Open
$this->dispatchEvent(ContentEvents::CONTENT_DUPLICATE, new ContentEvent($duplicateContent));
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::getParameter
Open
$this->getParameter('open_orchestra_api.facade.content_collection.class'),
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::dispatchEvent
Open
$this->dispatchEvent(ContentEvents::CONTENT_DELETE_VERSION, new ContentEvent($content));
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::denyAccessUnlessGranted
Open
$this->denyAccessUnlessGranted(ContributionActionInterface::DELETE, $content);
- Create a ticketCreate a ticket
- Exclude checks
Reference to constant CONTENT_DELETE
from undeclared class \OpenOrchestra\ModelInterface\ContentEvents
Open
$this->dispatchEvent(ContentEvents::CONTENT_DELETE, new ContentDeleteEvent($contentId, $content->getSiteId()));
- Create a ticketCreate a ticket
- Exclude checks
Checking instanceof against undeclared class \OpenOrchestra\ModelInterface\Model\ContentInterface
Open
if (!$content instanceof ContentInterface) {
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$newContent = $this->get('open_orchestra_backoffice.manager.content')->newVersionContent($content, $facade->versionName);
- Create a ticketCreate a ticket
- Exclude checks
Reference to constant ENTITY_TYPE
from undeclared class \OpenOrchestra\ModelInterface\Model\ContentInterface
Open
$this->denyAccessUnlessGranted(ContributionActionInterface::READ, ContentInterface::ENTITY_TYPE);
- Create a ticketCreate a ticket
- Exclude checks
Call to method generateFromRequest
from undeclared class \OpenOrchestra\Pagination\Configuration\PaginateFinderConfiguration
Open
$configuration = PaginateFinderConfiguration::generateFromRequest($request, $mapping);
- Create a ticketCreate a ticket
- Exclude checks
Call to method __construct
from undeclared class \OpenOrchestra\ModelInterface\Event\ContentEvent
Open
$this->dispatchEvent(ContentEvents::CONTENT_DELETE_VERSION, new ContentEvent($content));
- Create a ticketCreate a ticket
- Exclude checks
Parameter $request
has undeclared type \Symfony\Component\HttpFoundation\Request
Open
public function deleteContentsAction(Request $request)
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$contents = $this->get('open_orchestra_api.transformer_manager')->reverseTransform('content_collection', $facade);
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$language = $this->get('open_orchestra_backoffice.context_backoffice_manager')->getSiteDefaultLanguage();
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
return $this->get('open_orchestra_api.transformer_manager')->transform('content', $content);
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$objectManager = $this->get('object_manager');
- Create a ticketCreate a ticket
- Exclude checks
@throws annotation of deleteAction
has suspicious class type \OpenOrchestra\ApiBundle\Exceptions\HttpException\ContentNotDeletableException,
which does not extend Error/Exception Open
public function deleteAction($contentId)
- Create a ticketCreate a ticket
- Exclude checks
Returning type array{}
but deleteAction()
is declared to return \Symfony\Component\HttpFoundation\Response
Open
return array();
- Create a ticketCreate a ticket
- Exclude checks
@throws annotation of newVersionAction
has suspicious class type \OpenOrchestra\ApiBundle\Exceptions\HttpException\ContentTypeNotAllowedException,
which does not extend Error/Exception Open
public function newVersionAction(Request $request, $contentId, $language, $originalVersion)
- Create a ticketCreate a ticket
- Exclude checks
Argument 3 (version)
is string
but \OpenOrchestra\ApiBundle\Controller\ContentController::findOneContent()
takes int|null
defined at /code/ApiBundle/Controller/ContentController.php:490
Open
$content = $this->findOneContent($contentId, $language, $originalVersion);
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$objectManager = $this->get('object_manager');
- Create a ticketCreate a ticket
- Exclude checks
Return type of listAction()
is undeclared type \OpenOrchestra\BaseApi\Facade\FacadeInterface
Open
public function listAction(Request $request, $contentTypeId, $siteId, $language)
- Create a ticketCreate a ticket
- Exclude checks
Return type of duplicateAction()
is undeclared type \Symfony\Component\HttpFoundation\Response
Open
public function duplicateAction(Request $request)
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::isGranted
Open
if ($this->isGranted(ContributionActionInterface::DELETE, $content) &&
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
return $this->get('open_orchestra_api.transformer_manager')->transform('content_collection', $contents);
- Create a ticketCreate a ticket
- Exclude checks
@throws annotation of listVersionAction
has suspicious class type \OpenOrchestra\ApiBundle\Exceptions\HttpException\ContentTypeNotAllowedException,
which does not extend Error/Exception Open
public function listVersionAction($contentId, $language)
- Create a ticketCreate a ticket
- Exclude checks
Returning type array{}
but changeStatusAction()
is declared to return \Symfony\Component\HttpFoundation\Response
Open
return array();
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$this->get('object_manager')->flush();
- Create a ticketCreate a ticket
- Exclude checks
Call to method getDefaultListable
from undeclared class \OpenOrchestra\ModelInterface\Model\ContentTypeInterface
Open
foreach ($contentType->getDefaultListable() as $column => $isListable) {
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$facade = $this->get('jms_serializer')->deserialize(
- Create a ticketCreate a ticket
- Exclude checks
Call to method __construct
from undeclared class \OpenOrchestra\ModelInterface\Event\ContentDeleteEvent
Open
$this->dispatchEvent(ContentEvents::CONTENT_DELETE, new ContentDeleteEvent($contentId, $content->getSiteId()));
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$repository = $this->get('open_orchestra_model.repository.content');
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::denyAccessUnlessGranted
Open
$this->denyAccessUnlessGranted(ContributionActionInterface::EDIT, $content);
- Create a ticketCreate a ticket
- Exclude checks
Reference to constant CONTENT_DUPLICATE
from undeclared class \OpenOrchestra\ModelInterface\ContentEvents
Open
$this->dispatchEvent(ContentEvents::CONTENT_DUPLICATE, new ContentEvent($newContent));
- Create a ticketCreate a ticket
- Exclude checks
Call to method __construct
from undeclared class \OpenOrchestra\ModelInterface\Event\ContentEvent
Open
$this->dispatchEvent(ContentEvents::CONTENT_DUPLICATE, new ContentEvent($newContent));
- Create a ticketCreate a ticket
- Exclude checks
@throws annotation of newLanguageAction
has suspicious class type \OpenOrchestra\ApiBundle\Exceptions\HttpException\ContentNotFoundHttpException,
which does not extend Error/Exception Open
public function newLanguageAction($contentId, $language)
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::denyAccessUnlessGranted
Open
$this->denyAccessUnlessGranted(ContributionActionInterface::READ, $content);
- Create a ticketCreate a ticket
- Exclude checks
Parameter $request
has undeclared type \Symfony\Component\HttpFoundation\Request
Open
public function changeStatusAction(Request $request, $saveOldPublishedVersion)
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$contentRepository = $this->get('open_orchestra_model.repository.content');
- Create a ticketCreate a ticket
- Exclude checks
Call to method getSiteId
from undeclared class \OpenOrchestra\ModelInterface\Model\ContentInterface
Open
$content->getSiteId()
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$repository = $this->get('open_orchestra_model.repository.content');
- Create a ticketCreate a ticket
- Exclude checks
Parameter $request
has undeclared type \Symfony\Component\HttpFoundation\Request
Open
public function duplicateAction(Request $request)
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
if (!$this->get('open_orchestra_backoffice.business_rules_manager')->isGranted(BusinessActionInterface::READ, $content)) {
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::getParameter
Open
$frontLanguages = $this->getParameter('open_orchestra_backoffice.orchestra_choice.front_language');
- Create a ticketCreate a ticket
- Exclude checks
Return type of deleteContentsAction()
is undeclared type \Symfony\Component\HttpFoundation\Response
Open
public function deleteContentsAction(Request $request)
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$repository = $this->get('open_orchestra_model.repository.content');
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::dispatchEvent
Open
$this->dispatchEvent(ContentEvents::CONTENT_DELETE, new ContentDeleteEvent($contentId, $content->getSiteId()));
- Create a ticketCreate a ticket
- Exclude checks
Returning type array{}
but deleteContentsAction()
is declared to return \Symfony\Component\HttpFoundation\Response
Open
return array();
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$this->get('object_manager')->remove($oldPublishedVersion);
- Create a ticketCreate a ticket
- Exclude checks
Possibly zero references to use statement for classlike/namespace Config
(\Sensio\Bundle\FrameworkExtraBundle\Configuration)
Open
use Sensio\Bundle\FrameworkExtraBundle\Configuration as Config;
- Create a ticketCreate a ticket
- Exclude checks
Call to method get
from undeclared class \Symfony\Component\HttpFoundation\Request
Open
$format = $request->get('_format', 'json');
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$this->get('open_orchestra_backoffice.business_rules_manager')->isGranted(BusinessActionInterface::DELETE, $content) &&
- Create a ticketCreate a ticket
- Exclude checks
Reference to constant CONTENT_DELETE
from undeclared class \OpenOrchestra\ModelInterface\ContentEvents
Open
$this->dispatchEvent(ContentEvents::CONTENT_DELETE, new ContentDeleteEvent($contentId, $content->getSiteId()));
- Create a ticketCreate a ticket
- Exclude checks
Call to method __construct
from undeclared class \OpenOrchestra\ModelInterface\Event\ContentDeleteEvent
Open
$this->dispatchEvent(ContentEvents::CONTENT_DELETE, new ContentDeleteEvent($contentId, $content->getSiteId()));
- Create a ticketCreate a ticket
- Exclude checks
Reference to constant CONTENT_CREATION
from undeclared class \OpenOrchestra\ModelInterface\ContentEvents
Open
array(ContentEvents::CONTENT_CREATION, ContentEvents::CONTENT_UPDATE),
- Create a ticketCreate a ticket
- Exclude checks
@throws annotation of newVersionAction
has suspicious class type \OpenOrchestra\ApiBundle\Exceptions\HttpException\ContentNotFoundHttpException,
which does not extend Error/Exception Open
public function newVersionAction(Request $request, $contentId, $language, $originalVersion)
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
if (!$this->get('open_orchestra_backoffice.business_rules_manager')->isGranted(BusinessActionInterface::READ, $content)) {
- Create a ticketCreate a ticket
- Exclude checks
@throws annotation of newLanguageAction
has suspicious class type \OpenOrchestra\ApiBundle\Exceptions\HttpException\ContentTypeNotAllowedException,
which does not extend Error/Exception Open
public function newLanguageAction($contentId, $language)
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::dispatchEvent
Open
$this->dispatchEvent(ContentEvents::CONTENT_DUPLICATE, new ContentEvent($newContent));
- Create a ticketCreate a ticket
- Exclude checks
@throws annotation of listStatusesForContentAction
has suspicious class type \OpenOrchestra\ApiBundle\Exceptions\HttpException\ContentTypeNotAllowedException,
which does not extend Error/Exception Open
public function listStatusesForContentAction($contentId, $language, $version)
- Create a ticketCreate a ticket
- Exclude checks
Call to method getStatus
from undeclared class \OpenOrchestra\ModelInterface\Model\ContentInterface
Open
if ($status !== $contentSource->getStatus()) {
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$oldPublishedVersion = $this->get('open_orchestra_model.repository.content')->findOnePublished(
- Create a ticketCreate a ticket
- Exclude checks
Class extends undeclared class \OpenOrchestra\BaseApiBundle\Controller\BaseController
Open
class ContentController extends BaseController
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$contentType = $this->get('open_orchestra_model.repository.content_type')->findOneByContentTypeIdInLastVersion($contentTypeId);
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::getParameter
Open
$this->getParameter('open_orchestra_api.facade.content.class'),
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::denyAccessUnlessGranted
Open
$this->denyAccessUnlessGranted(ContributionActionInterface::CREATE, $content);
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$duplicateContent = $this->get('open_orchestra_backoffice.manager.content')->duplicateContent($content, $newContentId);
- Create a ticketCreate a ticket
- Exclude checks
Call to method get
from undeclared class \Symfony\Component\HttpFoundation\Request
Open
$format = $request->get('_format', 'json');
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$this->get('open_orchestra_backoffice.business_rules_manager')->isGranted(ContentStrategy::DELETE_VERSION, $content)
- Create a ticketCreate a ticket
- Exclude checks
Call to method get
from undeclared class \Symfony\Component\HttpFoundation\Request
Open
$format = $request->get('_format', 'json');
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$siteId = $this->get('open_orchestra_backoffice.context_backoffice_manager')->getSiteId();
- Create a ticketCreate a ticket
- Exclude checks
Reference to constant CONTENT_DUPLICATE
from undeclared class \OpenOrchestra\ModelInterface\ContentEvents
Open
$this->dispatchEvent(ContentEvents::CONTENT_DUPLICATE, new ContentEvent($newContent));
- Create a ticketCreate a ticket
- Exclude checks
Return type of listVersionAction()
is undeclared type \Symfony\Component\HttpFoundation\Response
Open
public function listVersionAction($contentId, $language)
- Create a ticketCreate a ticket
- Exclude checks
@throws annotation of showAction
has suspicious class type \OpenOrchestra\ApiBundle\Exceptions\HttpException\ContentTypeNotAllowedException,
which does not extend Error/Exception Open
public function showAction($contentId, $language, $version)
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
if (!$this->get('open_orchestra_backoffice.business_rules_manager')->isGranted(BusinessActionInterface::READ, $content)) {
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::denyAccessUnlessGranted
Open
$this->denyAccessUnlessGranted(ContributionActionInterface::READ, $content);
- Create a ticketCreate a ticket
- Exclude checks
Returning type \OpenOrchestra\WorkflowAdminBundle\Facade\StatusCollectionFacade
but listStatusesForContentAction()
is declared to return \Symfony\Component\HttpFoundation\Response
Open
return $this->listStatuses($content);
- Create a ticketCreate a ticket
- Exclude checks
@throws annotation of listAction
has suspicious class type \OpenOrchestra\ApiBundle\Exceptions\HttpException\ContentTypeNotAllowedException,
which does not extend Error/Exception Open
public function listAction(Request $request, $contentTypeId, $siteId, $language)
- Create a ticketCreate a ticket
- Exclude checks
@throws annotation of changeStatusAction
has suspicious class type \OpenOrchestra\ApiBundle\Exceptions\HttpException\ContentNotFoundHttpException,
which does not extend Error/Exception Open
public function changeStatusAction(Request $request, $saveOldPublishedVersion)
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$facade = $this->get('open_orchestra_api.transformer_manager')->transform('content_collection', $collection);
- Create a ticketCreate a ticket
- Exclude checks
Parameter $content
has undeclared type \OpenOrchestra\ModelInterface\Model\ContentInterface
Open
protected function updateStatus(
- Create a ticketCreate a ticket
- Exclude checks
Call to method getLanguage
from undeclared class \OpenOrchestra\ModelInterface\Model\ContentInterface
Open
$content->getLanguage(),
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::dispatchEvent
Open
$this->dispatchEvent(ContentEvents::CONTENT_DUPLICATE, new ContentEvent($duplicateContent));
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::dispatchEvent
Open
$this->dispatchEvent(ContentEvents::CONTENT_CHANGE_STATUS, $event);
- Create a ticketCreate a ticket
- Exclude checks
Returning type array{}
but deleteContentVersionsAction()
is declared to return \Symfony\Component\HttpFoundation\Response
Open
return array();
- Create a ticketCreate a ticket
- Exclude checks
Call to method getContent
from undeclared class \Symfony\Component\HttpFoundation\Request
Open
$request->getContent(),
- Create a ticketCreate a ticket
- Exclude checks
Returning type array{}
but newVersionAction()
is declared to return \Symfony\Component\HttpFoundation\Response
Open
return array();
- Create a ticketCreate a ticket
- Exclude checks
Parameter $request
has undeclared type \Symfony\Component\HttpFoundation\Request
Open
public function listAction(Request $request, $contentTypeId, $siteId, $language)
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$this->get('open_orchestra_model.repository.content')->removeContentVersion($storageIds);
- Create a ticketCreate a ticket
- Exclude checks
@throws annotation of deleteAction
has suspicious class type \OpenOrchestra\ApiBundle\Exceptions\HttpException\ContentTypeNotAllowedException,
which does not extend Error/Exception Open
public function deleteAction($contentId)
- Create a ticketCreate a ticket
- Exclude checks
Return type of listContentByAuthorAndSiteIdAction()
is undeclared type \OpenOrchestra\BaseApi\Facade\FacadeInterface
Open
public function listContentByAuthorAndSiteIdAction($published)
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
return $this->get('open_orchestra_api.transformer_manager')->get('content_collection')->transform(array());
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$contents = $this->get('open_orchestra_model.repository.content')->findNotDeletedSortByUpdatedAt($contentId, $language);
- Create a ticketCreate a ticket
- Exclude checks
Call to method get
from undeclared class \Symfony\Component\HttpFoundation\Request
Open
$request->get('_format', 'json')
- Create a ticketCreate a ticket
- Exclude checks
Parameter $contentSource
has undeclared type \OpenOrchestra\ModelInterface\Model\ContentInterface
Open
protected function updateStatus(
- Create a ticketCreate a ticket
- Exclude checks
Checking instanceof against undeclared class \OpenOrchestra\ModelInterface\Model\ContentInterface
Open
if (!$content instanceof ContentInterface) {
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
if (!$this->get('open_orchestra_backoffice.business_rules_manager')->isGranted(BusinessActionInterface::READ, $content)) {
- Create a ticketCreate a ticket
- Exclude checks
Call to method getStatus
from undeclared class \OpenOrchestra\ModelInterface\Model\ContentInterface
Open
if (true === $content->getStatus()->isPublishedState() && false === $saveOldPublishedVersion) {
- Create a ticketCreate a ticket
- Exclude checks
Checking instanceof against undeclared class \OpenOrchestra\ModelInterface\Model\ContentInterface
Open
if ($content instanceof ContentInterface) {
- Create a ticketCreate a ticket
- Exclude checks
Returning type array{}
but duplicateAction()
is declared to return \Symfony\Component\HttpFoundation\Response
Open
return array();
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::dispatchEvent
Open
$this->dispatchEvent(ContentEvents::CONTENT_DELETE, new ContentDeleteEvent($contentId, $content->getSiteId()));
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$user = $this->get('security.token_storage')->getToken()->getUser();
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$contents = $this->get('open_orchestra_model.repository.content')->findByHistoryAndSiteId(
- Create a ticketCreate a ticket
- Exclude checks
Call to method getContent
from undeclared class \Symfony\Component\HttpFoundation\Request
Open
$request->getContent(),
- Create a ticketCreate a ticket
- Exclude checks
Return type of newLanguageAction()
is undeclared type \Symfony\Component\HttpFoundation\Response
Open
public function newLanguageAction($contentId, $language)
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
if (!$this->get('open_orchestra_backoffice.business_rules_manager')->isGranted(BusinessActionInterface::READ, $content)) {
- Create a ticketCreate a ticket
- Exclude checks
Returning type array{}
but newLanguageAction()
is declared to return \Symfony\Component\HttpFoundation\Response
Open
return array();
- Create a ticketCreate a ticket
- Exclude checks
Argument 1 (document)
is \OpenOrchestra\ModelInterface\Model\ContentInterface
but \OpenOrchestra\ApiBundle\Controller\ContentController::listStatuses()
takes \OpenOrchestra\ModelInterface\Model\StatusableInterface
defined at /code/ApiBundle/Controller/ControllerTrait/ListStatus.php:17
Open
return $this->listStatuses($content);
- Create a ticketCreate a ticket
- Exclude checks
Call to method getStatus
from undeclared class \OpenOrchestra\ModelInterface\Model\ContentInterface
Open
$status = $content->getStatus();
- Create a ticketCreate a ticket
- Exclude checks
Checking instanceof against undeclared class \OpenOrchestra\ModelInterface\Model\ContentInterface
Open
if (!$content instanceof ContentInterface) {
- Create a ticketCreate a ticket
- Exclude checks
Call to method getContent
from undeclared class \Symfony\Component\HttpFoundation\Request
Open
$request->getContent(),
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::isGranted
Open
if (!$this->isGranted($status, $contentSource)) {
- Create a ticketCreate a ticket
- Exclude checks
Return type of findOneContent()
is undeclared type \OpenOrchestra\ModelInterface\Model\ContentInterface
Open
protected function findOneContent($contentId, $language, $version = null)
- Create a ticketCreate a ticket
- Exclude checks
Checking instanceof against undeclared class \OpenOrchestra\ModelInterface\Model\ContentInterface
Open
if ($oldPublishedVersion instanceof ContentInterface) {
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::denyAccessUnlessGranted
Open
$this->denyAccessUnlessGranted(ContributionActionInterface::READ, ContentInterface::ENTITY_TYPE);
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$facade = $this->get('jms_serializer')->deserialize(
- Create a ticketCreate a ticket
- Exclude checks
Parameter $request
has undeclared type \Symfony\Component\HttpFoundation\Request
Open
public function deleteContentVersionsAction(Request $request)
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$facade = $this->get('jms_serializer')->deserialize(
- Create a ticketCreate a ticket
- Exclude checks
Call to method getContent
from undeclared class \Symfony\Component\HttpFoundation\Request
Open
$request->getContent(),
- Create a ticketCreate a ticket
- Exclude checks
Reference to constant CONTENT_DELETE_VERSION
from undeclared class \OpenOrchestra\ModelInterface\ContentEvents
Open
$this->dispatchEvent(ContentEvents::CONTENT_DELETE_VERSION, new ContentEvent($content));
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::denyAccessUnlessGranted
Open
$this->denyAccessUnlessGranted(ContributionActionInterface::DELETE, $content);
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
if (!$this->get('open_orchestra_backoffice.business_rules_manager')->isGranted(BusinessActionInterface::DELETE, $content)) {
- Create a ticketCreate a ticket
- Exclude checks
Parameter $request
has undeclared type \Symfony\Component\HttpFoundation\Request
Open
public function newVersionAction(Request $request, $contentId, $language, $originalVersion)
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$content = $this->get('open_orchestra_model.repository.content')->find($facade->id);
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
if (!$this->get('open_orchestra_backoffice.business_rules_manager')->isGranted(BusinessActionInterface::READ, $content)) {
- Create a ticketCreate a ticket
- Exclude checks
@throws annotation of showAction
has suspicious class type \OpenOrchestra\ApiBundle\Exceptions\HttpException\ContentNotFoundHttpException,
which does not extend Error/Exception Open
public function showAction($contentId, $language, $version)
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
if (!$this->get('open_orchestra_backoffice.business_rules_manager')->isGranted(BusinessActionInterface::READ, $content)) {
- Create a ticketCreate a ticket
- Exclude checks
Call to method getContent
from undeclared class \Symfony\Component\HttpFoundation\Request
Open
$request->getContent(),
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::isGranted
Open
$this->isGranted(ContributionActionInterface::DELETE, $content)
- Create a ticketCreate a ticket
- Exclude checks
Return type of deleteAction()
is undeclared type \Symfony\Component\HttpFoundation\Response
Open
public function deleteAction($contentId)
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::denyAccessUnlessGranted
Open
$this->denyAccessUnlessGranted(ContributionActionInterface::EDIT, $content);
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$objectManager = $this->get('object_manager');
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$facade = $this->get('jms_serializer')->deserialize(
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::denyAccessUnlessGranted
Open
$this->denyAccessUnlessGranted(ContributionActionInterface::EDIT, $content);
- Create a ticketCreate a ticket
- Exclude checks
Call to method getStatus
from undeclared class \OpenOrchestra\ModelInterface\Model\ContentInterface
Open
$event = new ContentEvent($content, $contentSource->getStatus());
- Create a ticketCreate a ticket
- Exclude checks
Reference to constant CONTENT_CHANGE_STATUS
from undeclared class \OpenOrchestra\ModelInterface\ContentEvents
Open
$this->dispatchEvent(ContentEvents::CONTENT_CHANGE_STATUS, $event);
- Create a ticketCreate a ticket
- Exclude checks
Parameter $contentType
has undeclared type \OpenOrchestra\ModelInterface\Model\ContentTypeInterface
Open
protected function getMappingContentType($language, ContentTypeInterface $contentType)
- Create a ticketCreate a ticket
- Exclude checks
Call to method getFields
from undeclared class \OpenOrchestra\ModelInterface\Model\ContentTypeInterface
Open
foreach ($contentType->getFields() as $field) {
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$newContent = $this->get('open_orchestra_backoffice.manager.content')->createNewLanguageContent($content, $language);
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
return $this->get('open_orchestra_api.transformer_manager')->transform('content_collection', $contents);
- Create a ticketCreate a ticket
- Exclude checks
Return type of listStatusesForContentAction()
is undeclared type \Symfony\Component\HttpFoundation\Response
Open
public function listStatusesForContentAction($contentId, $language, $version)
- Create a ticketCreate a ticket
- Exclude checks
Call to method __construct
from undeclared class \OpenOrchestra\ModelInterface\Event\ContentEvent
Open
$this->dispatchEvent(ContentEvents::CONTENT_DUPLICATE, new ContentEvent($newContent));
- Create a ticketCreate a ticket
- Exclude checks
@throws annotation of listStatusesForContentAction
has suspicious class type \OpenOrchestra\ApiBundle\Exceptions\HttpException\ContentNotFoundHttpException,
which does not extend Error/Exception Open
public function listStatusesForContentAction($contentId, $language, $version)
- Create a ticketCreate a ticket
- Exclude checks
Argument 3 (version)
is string
but \OpenOrchestra\ApiBundle\Controller\ContentController::findOneContent()
takes int|null
defined at /code/ApiBundle/Controller/ContentController.php:490
Open
$content = $this->findOneContent($contentId, $language, $version);
- Create a ticketCreate a ticket
- Exclude checks
@throws annotation of changeStatusAction
has suspicious class type \OpenOrchestra\ApiBundle\Exceptions\HttpException\StatusChangeNotGrantedHttpException,
which does not extend Error/Exception Open
public function changeStatusAction(Request $request, $saveOldPublishedVersion)
- Create a ticketCreate a ticket
- Exclude checks
Return type of changeStatusAction()
is undeclared type \Symfony\Component\HttpFoundation\Response
Open
public function changeStatusAction(Request $request, $saveOldPublishedVersion)
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$this->get('open_orchestra_api.transformer_manager')->reverseTransform('content', $facade, array('source' => $content));
- Create a ticketCreate a ticket
- Exclude checks
Call to method getContentId
from undeclared class \OpenOrchestra\ModelInterface\Model\ContentInterface
Open
$content->getContentId(),
- Create a ticketCreate a ticket
- Exclude checks
Call to method __construct
from undeclared class \OpenOrchestra\ModelInterface\Event\ContentEvent
Open
$event = new ContentEvent($content, $contentSource->getStatus());
- Create a ticketCreate a ticket
- Exclude checks
Call to undeclared method \OpenOrchestra\ApiBundle\Controller\ContentController::get
Open
$content = $this->get('open_orchestra_model.repository.content')->findLastVersion($contentId);
- Create a ticketCreate a ticket
- Exclude checks
@throws annotation of changeStatusAction
has suspicious class type \OpenOrchestra\ApiBundle\Exceptions\HttpException\ContentTypeNotAllowedException,
which does not extend Error/Exception Open
public function changeStatusAction(Request $request, $saveOldPublishedVersion)
- Create a ticketCreate a ticket
- Exclude checks
Checking instanceof against undeclared class \OpenOrchestra\ModelInterface\Model\ContentInterface
Open
if (!$content instanceof ContentInterface) {
- Create a ticketCreate a ticket
- Exclude checks
Avoid excessively long variable names like $availableContentTypes. Keep variable name length under 20. Open
$availableContentTypes = $site->getContentTypes();
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
LongVariable
Since: 0.2
Detects when a field, formal or local variable is declared with a long name.
Example
class Something {
protected $reallyLongIntName = -3; // VIOLATION - Field
public static function main( array $interestingArgumentsList[] ) { // VIOLATION - Formal
$otherReallyLongName = -5; // VIOLATION - Local
for ($interestingIntIndex = 0; // VIOLATION - For
$interestingIntIndex < 10;
$interestingIntIndex++ ) {
}
}
}
Source https://phpmd.org/rules/naming.html#longvariable
Avoid excessively long variable names like $saveOldPublishedVersion. Keep variable name length under 20. Open
public function changeStatusAction(Request $request, $saveOldPublishedVersion)
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
LongVariable
Since: 0.2
Detects when a field, formal or local variable is declared with a long name.
Example
class Something {
protected $reallyLongIntName = -3; // VIOLATION - Field
public static function main( array $interestingArgumentsList[] ) { // VIOLATION - Formal
$otherReallyLongName = -5; // VIOLATION - Local
for ($interestingIntIndex = 0; // VIOLATION - For
$interestingIntIndex < 10;
$interestingIntIndex++ ) {
}
}
}
Source https://phpmd.org/rules/naming.html#longvariable
Avoid excessively long variable names like $saveOldPublishedVersion. Keep variable name length under 20. Open
$saveOldPublishedVersion
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
LongVariable
Since: 0.2
Detects when a field, formal or local variable is declared with a long name.
Example
class Something {
protected $reallyLongIntName = -3; // VIOLATION - Field
public static function main( array $interestingArgumentsList[] ) { // VIOLATION - Formal
$otherReallyLongName = -5; // VIOLATION - Local
for ($interestingIntIndex = 0; // VIOLATION - For
$interestingIntIndex < 10;
$interestingIntIndex++ ) {
}
}
}
Source https://phpmd.org/rules/naming.html#longvariable
Line exceeds 120 characters; contains 130 characters Open
if (!$this->get('open_orchestra_backoffice.business_rules_manager')->isGranted(BusinessActionInterface::READ, $content)) {
- Create a ticketCreate a ticket
- Exclude checks
Line exceeds 120 characters; contains 125 characters Open
$newContent = $this->get('open_orchestra_backoffice.manager.content')->createNewLanguageContent($content, $language);
- Create a ticketCreate a ticket
- Exclude checks
Line exceeds 120 characters; contains 128 characters Open
$contents = $this->get('open_orchestra_model.repository.content')->findNotDeletedSortByUpdatedAt($contentId, $language);
- Create a ticketCreate a ticket
- Exclude checks
Line exceeds 120 characters; contains 132 characters Open
$this->get('open_orchestra_backoffice.business_rules_manager')->isGranted(ContentStrategy::DELETE_VERSION, $content)
- Create a ticketCreate a ticket
- Exclude checks
Line exceeds 120 characters; contains 132 characters Open
if (!$this->get('open_orchestra_backoffice.business_rules_manager')->isGranted(BusinessActionInterface::DELETE, $content)) {
- Create a ticketCreate a ticket
- Exclude checks
Line exceeds 120 characters; contains 129 characters Open
$newContent = $this->get('open_orchestra_backoffice.manager.content')->newVersionContent($content, $facade->versionName);
- Create a ticketCreate a ticket
- Exclude checks
Line exceeds 120 characters; contains 130 characters Open
if (!$this->get('open_orchestra_backoffice.business_rules_manager')->isGranted(BusinessActionInterface::READ, $content)) {
- Create a ticketCreate a ticket
- Exclude checks
Line exceeds 120 characters; contains 129 characters Open
$mapping['fields.' . $field->getFieldId() . '.string_value'] = 'attributes.' . $field->getFieldId() . '.stringValue';
- Create a ticketCreate a ticket
- Exclude checks
Line exceeds 120 characters; contains 154 characters Open
* @Config\Route("/list/not-published-by-author", name="open_orchestra_api_content_list_author_and_site_not_published", defaults={"published": false})
- Create a ticketCreate a ticket
- Exclude checks
Line exceeds 120 characters; contains 151 characters Open
$recordsFiltered = $repository->countWithFilterAndContentTypeSiteAndLanguage($configuration, $contentTypeId, $siteId, $language, $searchTypes);
- Create a ticketCreate a ticket
- Exclude checks
Line exceeds 120 characters; contains 122 characters Open
$contents = $this->get('open_orchestra_api.transformer_manager')->reverseTransform('content_collection', $facade);
- Create a ticketCreate a ticket
- Exclude checks
Line exceeds 120 characters; contains 130 characters Open
if (!$this->get('open_orchestra_backoffice.business_rules_manager')->isGranted(BusinessActionInterface::READ, $content)) {
- Create a ticketCreate a ticket
- Exclude checks
Line exceeds 120 characters; contains 151 characters Open
$collection = $repository->findForPaginateFilterByContentTypeSiteAndLanguage($configuration, $contentTypeId, $siteId, $language, $searchTypes);
- Create a ticketCreate a ticket
- Exclude checks
Line exceeds 120 characters; contains 134 characters Open
if (!$this->get('open_orchestra_backoffice.business_rules_manager')->isGranted(BusinessActionInterface::READ, $content)) {
- Create a ticketCreate a ticket
- Exclude checks
Line exceeds 120 characters; contains 122 characters Open
$contents = $this->get('open_orchestra_api.transformer_manager')->reverseTransform('content_collection', $facade);
- Create a ticketCreate a ticket
- Exclude checks
Line exceeds 120 characters; contains 127 characters Open
$this->dispatchEvent(ContentEvents::CONTENT_DELETE, new ContentDeleteEvent($contentId, $content->getSiteId()));
- Create a ticketCreate a ticket
- Exclude checks
Line exceeds 120 characters; contains 128 characters Open
$this->get('open_orchestra_api.transformer_manager')->reverseTransform('content', $facade, array('source' => $content));
- Create a ticketCreate a ticket
- Exclude checks
Line exceeds 120 characters; contains 130 characters Open
if (!$this->get('open_orchestra_backoffice.business_rules_manager')->isGranted(BusinessActionInterface::READ, $content)) {
- Create a ticketCreate a ticket
- Exclude checks
Line exceeds 120 characters; contains 135 characters Open
$duplicateContent = $this->get('open_orchestra_backoffice.manager.content')->duplicateContent($content, $newContentId);
- Create a ticketCreate a ticket
- Exclude checks
Line exceeds 120 characters; contains 135 characters Open
$contentType = $this->get('open_orchestra_model.repository.content_type')->findOneByContentTypeIdInLastVersion($contentTypeId);
- Create a ticketCreate a ticket
- Exclude checks
Line exceeds 120 characters; contains 130 characters Open
if (!$this->get('open_orchestra_backoffice.business_rules_manager')->isGranted(BusinessActionInterface::READ, $content)) {
- Create a ticketCreate a ticket
- Exclude checks
Line exceeds 120 characters; contains 135 characters Open
if (!$this->get('open_orchestra_backoffice.business_rules_manager')->isGranted(ContentTypeStrategy::READ_LIST, $contentType)) {
- Create a ticketCreate a ticket
- Exclude checks
Line exceeds 120 characters; contains 135 characters Open
$this->get('open_orchestra_backoffice.business_rules_manager')->isGranted(BusinessActionInterface::DELETE, $content) &&
- Create a ticketCreate a ticket
- Exclude checks
Line exceeds 120 characters; contains 125 characters Open
* @Config\Route("/list/by-author", name="open_orchestra_api_content_list_author_and_site", defaults={"published": null})
- Create a ticketCreate a ticket
- Exclude checks
Line exceeds 120 characters; contains 130 characters Open
if (!$this->get('open_orchestra_backoffice.business_rules_manager')->isGranted(BusinessActionInterface::READ, $content)) {
- Create a ticketCreate a ticket
- Exclude checks
Expected 0 spaces after opening bracket; newline found Open
if (
- Create a ticketCreate a ticket
- Exclude checks