EscolaLMS/Consultations

View on GitHub

Showing 1,241 of 1,241 total issues

Space before opening parenthesis of function call prohibited
Open

                    ->orWhereHas('teachers', fn (Builder $query) => $query->where('users.id', '=', auth()->user()->getKey()))

Space before opening parenthesis of function call prohibited
Open

            fn (Builder $query) => $query->where('consultation_user.consultation_id', '=', $this->value)

Space before opening parenthesis of function call prohibited
Open

            ->whereHas('consultationUser', fn (Builder $query) => $query->where('user_id', '=', $userId))

Multi-line function call not indented correctly; expected 20 spaces but found 24
Open

                        $reminderStatus,

Expected 0 spaces after opening bracket; newline found
Open

        if (

Expected 0 spaces before closing bracket; newline found
Open

                ->whereHas('consultation', fn (Builder $query) => $query

Space before opening parenthesis of function call prohibited
Open

            fn (Builder $query) => $query->whereIn('categories.id', $this->value)

Multi-line function call not indented correctly; expected 20 spaces but found 24
Open

                        $userTerm

Opening brace should be on a new line
Open

    public function __construct(array $params) {

Space before opening parenthesis of function call prohibited
Open

            ->whereHas('consultationUser', fn (Builder $query) => $query

Multi-line function call not indented correctly; expected 20 spaces but found 24
Open

                        $teacher,

Opening brace should be on a new line
Open

    public function __construct(array $params) {

Expected 0 spaces after opening bracket; newline found
Open

        if (

Space before opening parenthesis of function call prohibited
Open

        if ($terms->first(fn (ConsultationUserPivot $userPivot) => $userPivot->user_id === $userId) !== null) {

Space before opening parenthesis of function call prohibited
Open

        return $proposedTerms->map(fn(ConsultationProposedTerm $proposedTerm) => Carbon::make($proposedTerm->proposed_at))->filter(fn (Carbon $proposedTerm) => !in_array($proposedTerm, $busyTerms))->toArray();

Space before opening parenthesis of function call prohibited
Open

        return $query->whereHas('consultationUser', fn ($query) => $query->whereHas('user'));

Space before opening parenthesis of function call prohibited
Open

        if ($terms->first(fn (ConsultationUserPivot $userPivot) => $userPivot->user_id === $userId) !== null) {

The variable $executed_at is not named in camelCase.
Open

    public function __construct(int $consultation_user_id, int $consultation_id, string $executed_at, string $status, string $duration, ?User $author, ?string $finished_at = null, ?Collection $users = null)
    {
        $this->consultation_user_id = $consultation_user_id;
        $this->consultation_id = $consultation_id;
        $this->executed_at = $executed_at;

CamelCaseVariableName

Since: 0.2

It is considered best practice to use the camelCase notation to name variables.

Example

class ClassName {
    public function doSomething() {
        $data_module = new DataModule();
    }
}

Source

The variable $consultation_id is not named in camelCase.
Open

    public function __construct(int $consultation_user_id, int $consultation_id, string $executed_at, string $status, string $duration, ?User $author, ?string $finished_at = null, ?Collection $users = null)
    {
        $this->consultation_user_id = $consultation_user_id;
        $this->consultation_id = $consultation_id;
        $this->executed_at = $executed_at;

CamelCaseVariableName

Since: 0.2

It is considered best practice to use the camelCase notation to name variables.

Example

class ClassName {
    public function doSomething() {
        $data_module = new DataModule();
    }
}

Source

The variable $finished_at is not named in camelCase.
Open

    public function __construct(int $consultation_user_id, int $consultation_id, string $executed_at, string $status, string $duration, ?User $author, ?string $finished_at = null, ?Collection $users = null)
    {
        $this->consultation_user_id = $consultation_user_id;
        $this->consultation_id = $consultation_id;
        $this->executed_at = $executed_at;

CamelCaseVariableName

Since: 0.2

It is considered best practice to use the camelCase notation to name variables.

Example

class ClassName {
    public function doSomething() {
        $data_module = new DataModule();
    }
}

Source

Severity
Category
Status
Source
Language