src/CoreBundle/Entity/ResourceNode.php
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[ApiFilter(filterClass: PropertyFilter::class)]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[ORM\ManyToOne(targetEntity: self::class, cascade: ['persist'], inversedBy: 'children')]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[ORM\OrderBy(['id' => 'ASC'])]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[ORM\Column(type: 'datetime')]
- Exclude checks
Missing function doc comment Open
Open
public function addChild(self $resourceNode): static
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[ORM\GeneratedValue(strategy: 'AUTO')]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[ORM\JoinColumn(name: 'resource_type_id', referencedColumnName: 'id', nullable: false)]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[Groups(['ctool:read', 'c_tool_intro:read'])]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[ORM\Column(name: 'level', type: 'integer', nullable: true)]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[Gedmo\Slug(fields: ['title'])]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[ORM\ManyToOne(targetEntity: ResourceFormat::class, inversedBy: 'resourceNodes')]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[ORM\JoinColumn(name: 'parent_id', onDelete: 'CASCADE')]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[Groups(['resource_node:read', 'document:read'])]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[Assert\NotBlank]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[ORM\Column(type: 'datetime')]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[ORM\Column(type: 'boolean')]
- Exclude checks
Missing function doc comment Open
Open
public function addComment(ResourceComment $comment): self
- Exclude checks
You must use "/**" style comments for a class comment Open
Open
class ResourceNode implements Stringable
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[Groups(['resource_node:read', 'document:read', 'ctool:read', 'user_json:read', 'course:read'])]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[ORM\Column(type: 'uuid', unique: true)]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[ORM\Id]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[Groups(['resource_node:read'])]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[ORM\Column(name: 'path', type: 'text', nullable: true)]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[Groups(['resource_node:read', 'document:read'])]
- Exclude checks
Missing function doc comment Open
Open
public function getUuid(): ?UuidV4
- Exclude checks
Missing function doc comment Open
Open
public function getCreator(): ?User
- Exclude checks
Add a single space around assignment operators Open
Open
declare(strict_types=1);
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[Assert\NotBlank]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[Gedmo\TreePathSource]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[ORM\JoinColumn(name: 'resource_format_id', referencedColumnName: 'id')]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[Assert\NotNull]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[ApiResource(
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[ORM\OneToMany(mappedBy: 'parent', targetEntity: self::class, cascade: ['persist'])]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[Gedmo\TreeLevel]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[Groups(['resource_node:read', 'resource_node:write', 'document:read', 'document:write', 'message:read', 'personal_file:read'])]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[ApiFilter(filterClass: OrderFilter::class, properties: ['id', 'title', 'createdAt', 'updatedAt', 'firstResourceFile.size'])]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[ORM\Column(type: 'integer')]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[ORM\Column(name: 'title', type: 'string', length: 255, nullable: false)]
- Exclude checks
Missing function doc comment Open
Open
public function __toString(): string
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[ORM\Table(name: 'resource_node')]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[Gedmo\Tree(type: 'materializedPath')]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[ORM\ManyToOne(targetEntity: ResourceType::class, inversedBy: 'resourceNodes', cascade: ['persist'])]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[ORM\OneToMany(mappedBy: 'resourceNode', targetEntity: ResourceLink::class, cascade: ['persist', 'remove'])]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[MaxDepth(1)]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[Gedmo\Timestampable(on: 'create')]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[ORM\OneToMany(
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[Assert\NotNull]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[ORM\JoinColumn(name: 'creator_id', referencedColumnName: 'id', nullable: true, onDelete: 'CASCADE')]
- Exclude checks
Scope keyword "static" must be followed by a single space Open
Open
public function addChild(self $resourceNode): static
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[ORM\Entity(repositoryClass: ResourceNodeRepository::class)]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[ApiFilter(filterClass: SearchFilter::class, properties: ['title' => 'partial'])]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[Groups(['resource_node:read', 'resource_node:write', 'document:read', 'document:write'])]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[Groups(['resource_node:read', 'resource_node:write', 'document:write'])]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[Gedmo\Timestampable(on: 'update')]
- Exclude checks
Missing function doc comment Open
Open
public function __construct()
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[ORM\Column(name: 'slug', type: 'string', length: 255, nullable: false)]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[Groups(['resource_node:read'])]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[Gedmo\TreeParent]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[ORM\OneToMany(mappedBy: 'resourceNode', targetEntity: ResourceComment::class, cascade: ['persist', 'remove'])]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[ORM\HasLifecycleCallbacks]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[ORM\EntityListeners([ResourceNodeListener::class])]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[Groups(['resource_node:read', 'document:read'])]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[Groups(['resource_node:read', 'document:read'])]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[Groups(['resource_node:read', 'document:read'])]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[ORM\ManyToOne(targetEntity: User::class, cascade: ['persist'], inversedBy: 'resourceNodes')]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[Gedmo\TreePath(separator: '/', appendId: true)]
- Exclude checks
Missing function doc comment Open
Open
public function hasCreator(): bool
- Exclude checks
Missing function doc comment Open
Open
public function addResourceLink(ResourceLink $link): self
- Exclude checks
Missing function doc comment Open
Open
public function setTitle(string $title): self
- Exclude checks
Missing function doc comment Open
Open
public function getIcon(?string $additionalClass = null): string
- Exclude checks
Missing function doc comment Open
Open
public function addResourceFile(ResourceFile $resourceFile): static
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[Groups(['resource_node:read', 'document:read'])]
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[ORM\OneToOne(mappedBy: 'shortCutNode', targetEntity: CShortcut::class, cascade: ['persist', 'remove'])]
- Exclude checks
Missing function doc comment Open
Open
public function setCreator(?User $creator): self
- Exclude checks
Missing function doc comment Open
Open
public function isPublic(): bool
- Exclude checks
Missing function doc comment Open
Open
public function getResourceFormat(): ?ResourceFormat
- Exclude checks
Missing function doc comment Open
Open
public function isResourceFileAnImage(): bool
- Exclude checks
Missing function doc comment Open
Open
public function getThumbnail(RouterInterface $router): string
- Exclude checks
Missing function doc comment Open
Open
public function getResourceType(): ResourceType
- Exclude checks
Scope keyword "static" must be followed by a single space Open
Open
public function removeResourceFile(ResourceFile $resourceFile): static
- Exclude checks
You must use "/**" style comments for a function comment Open
Open
public function getFirstResourceFile(): ?ResourceFile
- Exclude checks
Missing function doc comment Open
Open
public function setSlug(string $slug): self
- Exclude checks
Missing function doc comment Open
Open
public function getTitle(): string
- Exclude checks
Missing function doc comment Open
Open
public function getResourceLinkByContext(
- Exclude checks
Scope keyword "static" must be followed by a single space Open
Open
public function addResourceFile(ResourceFile $resourceFile): static
- Exclude checks
Missing function doc comment Open
Open
public function setResourceLinks(Collection $resourceLinks): self
- Exclude checks
Missing function doc comment Open
Open
public function removeResourceFile(ResourceFile $resourceFile): static
- Exclude checks
Missing function doc comment Open
Open
public function getPathForDisplayRemoveBase(string $base): string
- Exclude checks
Missing function doc comment Open
Open
public function getSlug(): string
- Exclude checks
Missing function doc comment Open
Open
public function setResourceType(ResourceType $resourceType): self
- Exclude checks
Missing function doc comment Open
Open
public function hasEditableTextContent(): bool
- Exclude checks
Missing function doc comment Open
Open
public function hasResourceFile(): bool
- Exclude checks
Missing function doc comment Open
Open
public function getContent(): ?string
- Exclude checks
Missing function doc comment Open
Open
public function setContent(string $content): self
- Exclude checks
Missing function doc comment Open
Open
public function setShortCut(?CShortcut $shortCut): self
- Exclude checks
Missing function doc comment Open
Open
public function getPathForDisplayToArray(?int $baseRoot = null): array
- Exclude checks
Missing function doc comment Open
Open
public function setResourceFormat(?ResourceFormat $resourceFormat): self
- Exclude checks
Missing function doc comment Open
Open
public function isResourceFileAVideo(): bool
- Exclude checks
Missing function doc comment Open
Open
public function setPublic(bool $public): self
- Exclude checks
Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead. Open
Open
#[Groups(['resource_node:read', 'document:read', 'message:read', 'personal_file:read'])]
- Exclude checks
Missing function doc comment Open
Open
public function getShortCut(): ?CShortcut
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
protected string $slug;
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
protected ?User $creator;
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
protected ?ResourceNode $parent = null;
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function getCreator(): ?User
- Exclude checks
Line indented incorrectly; expected at least 16 spaces, found 12 Open
Open
$this->children->add($resourceNode);
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 4 spaces, found 0 Open
Open
)]
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function __toString(): string
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this->level;
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function addComment(ResourceComment $comment): self
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
protected string $title;
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
protected DateTime $updatedAt;
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
$this->children = new ArrayCollection();
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
protected ?int $id = null;
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
protected bool $fileEditableText;
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
protected ?string $content = null;
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
private Collection $resourceFiles;
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function getParent(): ?self
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
protected Collection $resourceLinks;
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
protected DateTime $createdAt;
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
)]
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this->path;
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this;
- Exclude checks
Line indented incorrectly; expected at least 16 spaces, found 12 Open
Open
$resourceNode->setParent($this);
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function getPath(): ?string
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function getPathForDisplayRemoveBase(string $base): string
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
protected ?CShortcut $shortCut = null;
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function __construct()
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return null !== $this->creator;
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function setCreator(?User $creator): self
- Exclude checks
Line indented incorrectly; expected 12 spaces, found 8 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
use TimestampableTypedEntity;
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
protected ?string $path = null;
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
protected bool $public;
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
protected ?UuidV4 $uuid = null;
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
$this->fileEditableText = false;
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this->uuid;
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this;
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this->comments;
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public const PATH_SEPARATOR = '/';
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
protected Collection $comments;
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
$this->resourceFiles = new ArrayCollection();
- Exclude checks
Line indented incorrectly; expected 12 spaces, found 8 Open
Open
foreach ($parts as $part) {
- Exclude checks
Line indented incorrectly; expected 4 spaces, found 0 Open
Open
class ResourceNode implements Stringable
- Exclude checks
Line indented incorrectly; expected at least 4 spaces, found 0 Open
Open
{
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function getPathForDisplay(): string
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this->parent;
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
$this->createdAt = new DateTime();
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this->getPathForDisplay();
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function addChild(self $resourceNode): static
- Exclude checks
Line indented incorrectly; expected 12 spaces, found 8 Open
Open
if (!$this->children->contains($resourceNode)) {
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function getLevel(): int
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected at least 16 spaces, found 12 Open
Open
$parts = explode('-', $part);
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function getUuid(): ?UuidV4
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this->creator;
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
$this->creator = $creator;
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this->children;
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this->path;
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
use TimestampableAgoTrait;
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
protected Collection $children;
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
protected ResourceType $resourceType;
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
$this->public = false;
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
$this->uuid = Uuid::v4();
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function setParent(?self $parent = null): self
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
$comment->setResourceNode($this);
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function getComments(): array|Collection
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this;
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
$this->comments->add($comment);
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
protected ?ResourceFormat $resourceFormat = null;
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
$this->resourceLinks = new ArrayCollection();
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function getChildren(): Collection
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this;
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected 16 spaces, found 12 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 20 spaces, found 16 Open
Open
continue;
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
$path = str_replace($base, '', $this->path);
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected at least 16 spaces, found 12 Open
Open
$message = 'Invalid character "'.self::PATH_SEPARATOR.'" in resource name';
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
$this->title = $title;
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected 16 spaces, found 12 Open
Open
}
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 20 spaces, found 16 Open
Open
Criteria::expr()->eq('session', $session)
- Exclude checks
Line indented incorrectly; expected at least 28 spaces, found 12 Open
Open
);
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
$this->resourceLinks->add($link);
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected 16 spaces, found 12 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return false;
- Exclude checks
Line indented incorrectly; expected at least 20 spaces, found 16 Open
Open
return true;
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function getId(): ?int
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this->resourceType;
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
$this->resourceType = $resourceType;
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this->public;
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected 12 spaces, found 8 Open
Open
if (str_contains(self::PATH_SEPARATOR, $slug)) {
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this->title;
- Exclude checks
Line indented incorrectly; expected at least 20 spaces, found 12 Open
Open
$criteria->andWhere(
- Exclude checks
Line indented incorrectly; expected 12 spaces, found 8 Open
Open
if ($resourceFile = $this->resourceFiles->first()) {
- Exclude checks
Line indented incorrectly; expected at least 16 spaces, found 12 Open
Open
$class = 'far fa-file';
- Exclude checks
Line indented incorrectly; expected 16 spaces, found 12 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 16 spaces, found 12 Open
Open
$url = $router->generate('chamilo_core_resource_view', $params);
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function getShortCut(): ?CShortcut
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this;
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
protected ?int $level = null;
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
$this->comments = new ArrayCollection();
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function hasCreator(): bool
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
$this->parent = $parent;
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function getPathForDisplayToArray(?int $baseRoot = null): array
- Exclude checks
Line indented incorrectly; expected 16 spaces, found 12 Open
Open
if (empty($parts[1])) {
- Exclude checks
Line indented incorrectly; expected at least 16 spaces, found 12 Open
Open
$id = $parts[1];
- Exclude checks
Line indented incorrectly; expected 12 spaces, found 8 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
$pathForDisplay = preg_replace('/-\d+\\'.self::PATH_SEPARATOR.'/', '/', $path);
- Exclude checks
Line indented incorrectly; expected at least 16 spaces, found 12 Open
Open
$pathForDisplay = substr_replace($pathForDisplay, '', -1);
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 4 Open
Open
): ?ResourceLink {
- Exclude checks
Line indented incorrectly; expected 16 spaces, found 8 Open
Open
if ($course) {
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected 16 spaces, found 12 Open
Open
if (str_contains($mimeType, 'image')) {
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 20 spaces, found 16 Open
Open
return true;
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this->getIcon('fa-3x');
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function getResourceFiles(): Collection
- Exclude checks
Line indented incorrectly; expected 12 spaces, found 8 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $list;
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function convertPathForDisplay(string $path): string
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected 12 spaces, found 8 Open
Open
}
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this->resourceLinks;
- Exclude checks
Line indented incorrectly; expected 16 spaces, found 8 Open
Open
if ($user) {
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
$this->resourceLinks = $resourceLinks;
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
$this->content = $content;
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this->resourceFormat;
- Exclude checks
Line indented incorrectly; expected at least 16 spaces, found 8 Open
Open
$criteria = Criteria::create();
- Exclude checks
Line indented incorrectly; expected at least 28 spaces, found 12 Open
Open
);
- Exclude checks
Line indented incorrectly; expected at least 20 spaces, found 16 Open
Open
Criteria::expr()->eq('group', $group)
- Exclude checks
Line indented incorrectly; expected 12 spaces, found 8 Open
Open
if ($this->hasResourceFile()) {
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function isResourceFileAVideo(): bool
- Exclude checks
Line indented incorrectly; expected at least 16 spaces, found 12 Open
Open
$mimeType = $resourceFile->getMimeType();
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return false;
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this;
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this->resourceFiles;
- Exclude checks
Line indented incorrectly; expected 12 spaces, found 8 Open
Open
if (!$this->resourceFiles->contains($resourceFile)) {
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected 12 spaces, found 8 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 16 spaces, found 12 Open
Open
Criteria::expr()->eq('resourceTypeGroup', $this->resourceType->getId())
- Exclude checks
Line indented incorrectly; expected at least 28 spaces, found 12 Open
Open
);
- Exclude checks
Line indented incorrectly; expected 16 spaces, found 12 Open
Open
if (str_contains($mimeType, 'text')) {
- Exclude checks
Line indented incorrectly; expected at least 20 spaces, found 16 Open
Open
return true;
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this->slug;
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected 16 spaces, found 8 Open
Open
}
- Exclude checks
Line indented incorrectly; expected 16 spaces, found 8 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 16 spaces, found 12 Open
Open
->resourceLinks
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this;
- Exclude checks
Line indented incorrectly; expected 12 spaces, found 8 Open
Open
}
- Exclude checks
Line indented incorrectly; expected 16 spaces, found 12 Open
Open
if ($this->isResourceFileAVideo()) {
- Exclude checks
Line indented incorrectly; expected 12 spaces, found 8 Open
Open
}
- Exclude checks
Line indented incorrectly; expected 16 spaces, found 12 Open
Open
if (str_contains($mimeType, 'video')) {
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected 16 spaces, found 12 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
$list = [];
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function getTitle(): string
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 16 spaces, found 8 Open
Open
$criteria->where(
- Exclude checks
Line indented incorrectly; expected at least 16 spaces, found 8 Open
Open
);
- Exclude checks
Line indented incorrectly; expected 16 spaces, found 8 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 20 spaces, found 12 Open
Open
$criteria->andWhere(
- Exclude checks
Line indented incorrectly; expected 16 spaces, found 8 Open
Open
if ($group) {
- Exclude checks
Line indented incorrectly; expected at least 16 spaces, found 12 Open
Open
$mimeType = $resourceFile->getMimeType();
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected 16 spaces, found 12 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function setContent(string $content): self
- Exclude checks
Line indented incorrectly; expected 12 spaces, found 8 Open
Open
if ($this->resourceFiles->removeElement($resourceFile)) {
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 16 spaces, found 12 Open
Open
$value = $parts[0];
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function getSlug(): string
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this;
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function setResourceFormat(?ResourceFormat $resourceFormat): self
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function getResourceLinkByContext(
- Exclude checks
Line indented incorrectly; expected at least 20 spaces, found 12 Open
Open
$criteria->andWhere(
- Exclude checks
Line indented incorrectly; expected 16 spaces, found 8 Open
Open
if ($session) {
- Exclude checks
Line indented incorrectly; expected 16 spaces, found 8 Open
Open
if ($usergroup) {
- Exclude checks
Line indented incorrectly; expected at least 16 spaces, found 8 Open
Open
;
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 16 spaces, found 12 Open
Open
$class .= " $additionalClass";
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return false;
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function isPublic(): bool
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function setPublic(bool $public): self
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
$this->public = $public;
- Exclude checks
Line indented incorrectly; expected 12 spaces, found 8 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this->resourceFiles->first() ?: null;
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected 12 spaces, found 8 Open
Open
if (null !== $pathForDisplay && '' !== $pathForDisplay) {
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
$title = str_replace('/', '-', $title);
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected 16 spaces, found 8 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 16 spaces, found 8 Open
Open
$first = $this
- Exclude checks
Line indented incorrectly; expected at least 16 spaces, found 8 Open
Open
return $first ?: null;
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function setResourceLinks(Collection $resourceLinks): self
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected at least 20 spaces, found 16 Open
Open
$class = 'far fa-file-image';
- Exclude checks
Line indented incorrectly; expected at least 20 spaces, found 16 Open
Open
$class = 'far fa-file-video';
- Exclude checks
Line indented incorrectly; expected 12 spaces, found 8 Open
Open
if ($resourceFile = $this->resourceFiles->first()) {
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected 12 spaces, found 8 Open
Open
if ($this->isResourceFileAnImage()) {
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this->id;
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function getResourceType(): ResourceType
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function setResourceType(ResourceType $resourceType): self
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this;
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this->resourceFiles->count() > 0;
- Exclude checks
Line indented incorrectly; expected at least 20 spaces, found 16 Open
Open
$resourceFile->setResourceNode(null);
- Exclude checks
Line indented incorrectly; expected 16 spaces, found 12 Open
Open
}
- Exclude checks
Line indented incorrectly; expected 12 spaces, found 8 Open
Open
if ($additionalClass) {
- Exclude checks
Line indented incorrectly; expected 12 spaces, found 8 Open
Open
}
- Exclude checks
Line indented incorrectly; expected 12 spaces, found 8 Open
Open
}
- Exclude checks
Line indented incorrectly; expected 12 spaces, found 8 Open
Open
}
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function getContent(): ?string
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this->shortCut;
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function addResourceFile(ResourceFile $resourceFile): static
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function getFirstResourceFile(): ?ResourceFile
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $pathForDisplay;
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function getResourceLinks(): Collection
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected at least 28 spaces, found 12 Open
Open
);
- Exclude checks
Line indented incorrectly; expected at least 20 spaces, found 16 Open
Open
Criteria::expr()->eq('userGroup', $usergroup)
- Exclude checks
Line indented incorrectly; expected at least 16 spaces, found 12 Open
Open
->first()
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this;
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
$link->setResourceNode($this);
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
$class = 'fa fa-folder';
- Exclude checks
Line indented incorrectly; expected 12 spaces, found 8 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 16 spaces, found 12 Open
Open
];
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this->content;
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function hasResourceFile(): bool
- Exclude checks
Line indented incorrectly; expected at least 20 spaces, found 16 Open
Open
continue;
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
$this->slug = $slug;
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function setTitle(string $title): self
- Exclude checks
Line indented incorrectly; expected 16 spaces, found 8 Open
Open
}
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function getIcon(?string $additionalClass = null): string
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this;
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
$this->shortCut = $shortCut;
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this;
- Exclude checks
Line indented incorrectly; expected at least 16 spaces, found 12 Open
Open
$this->resourceFiles->add($resourceFile);
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function removeResourceFile(ResourceFile $resourceFile): static
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
$parts = explode(self::PATH_SEPARATOR, $this->path);
- Exclude checks
Line indented incorrectly; expected 16 spaces, found 12 Open
Open
if (!empty($baseRoot) && $id < $baseRoot) {
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this->convertPathForDisplay($path);
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function getResourceFormat(): ?ResourceFormat
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
$this->resourceFormat = $resourceFormat;
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this;
- Exclude checks
Line indented incorrectly; expected at least 20 spaces, found 12 Open
Open
$criteria->andWhere(
- Exclude checks
Line indented incorrectly; expected at least 20 spaces, found 16 Open
Open
Criteria::expr()->eq('user', $user)
- Exclude checks
Line indented incorrectly; expected at least 16 spaces, found 12 Open
Open
->matching($criteria)
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function addResourceLink(ResourceLink $link): self
- Exclude checks
Line indented incorrectly; expected 16 spaces, found 12 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 16 spaces, found 12 Open
Open
$mimeType = $resourceFile->getMimeType();
- Exclude checks
Line indented incorrectly; expected at least 16 spaces, found 12 Open
Open
return \sprintf("<img src='%s'/>", $url);
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 16 spaces, found 12 Open
Open
$resourceFile->setResourceNode($this);
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this;
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 16 spaces, found 12 Open
Open
throw new InvalidArgumentException($message);
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return $this;
- Exclude checks
Line indented incorrectly; expected at least 20 spaces, found 16 Open
Open
Criteria::expr()->eq('course', $course)
- Exclude checks
Line indented incorrectly; expected at least 20 spaces, found 12 Open
Open
$criteria->andWhere(
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function hasEditableTextContent(): bool
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected 4 spaces, found 0 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 16 spaces, found 12 Open
Open
$list[$id] = $value;
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function setSlug(string $slug): self
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected at least 28 spaces, found 12 Open
Open
);
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
}
- Exclude checks
Line indented incorrectly; expected 16 spaces, found 12 Open
Open
if ($this->isResourceFileAnImage()) {
- Exclude checks
Line indented incorrectly; expected at least 12 spaces, found 8 Open
Open
return '<i class="'.$class.'"></i>';
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function isResourceFileAnImage(): bool
- Exclude checks
Line indented incorrectly; expected 12 spaces, found 8 Open
Open
if ($resourceFile = $this->resourceFiles->first()) {
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function getThumbnail(RouterInterface $router): string
- Exclude checks
Line indented incorrectly; expected at least 16 spaces, found 12 Open
Open
$params = [
- Exclude checks
Line indented incorrectly; expected at least 8 spaces, found 4 Open
Open
{
- Exclude checks
Line indented incorrectly; expected 8 spaces, found 4 Open
Open
public function setShortCut(?CShortcut $shortCut): self
- Exclude checks
Line indented incorrectly; expected 16 spaces, found 12 Open
Open
if ($resourceFile->getResourceNode() === $this) {
- Exclude checks