ernestwisniewski/kbin

View on GitHub
src/Entity/Post.php

Summary

Maintainability
A
35 mins
Test Coverage
C
71%

Post has 21 functions (exceeds 20 allowed). Consider refactoring.
Wontfix

#[Entity(repositoryClass: PostRepository::class)]
#[Index(columns: ['visibility', 'is_adult'], name: 'post_visibility_adult_idx')]
#[Index(columns: ['visibility'], name: 'post_visibility_idx')]
#[Index(columns: ['is_adult'], name: 'post_adult_idx')]
#[Index(columns: ['ranking'], name: 'post_ranking_idx')]
Severity: Minor
Found in src/Entity/Post.php - About 2 hrs to fix

    File Post.php has 251 lines of code (exceeds 250 allowed). Consider refactoring.
    Invalid

    <?php
    
    // SPDX-FileCopyrightText: 2023 /kbin contributors <https://kbin.pub/>
    //
    // SPDX-License-Identifier: AGPL-3.0-only
    Severity: Minor
    Found in src/Entity/Post.php - About 2 hrs to fix

      Method __construct has 5 arguments (exceeds 4 allowed). Consider refactoring.
      Open

              ?string $body,
              Magazine $magazine,
              User $user,
              bool $isAdult,
              string $ip = null
      Severity: Minor
      Found in src/Entity/Post.php - About 35 mins to fix

        There are no issues that match your filters.

        Category
        Status