StadGent/php_package_services-opening-hours

View on GitHub

Showing 57 of 79 total issues

Similar blocks of code found in 4 locations. Consider refactoring.
Open

    public function getWeek(int $serviceId, int $channelId, string $date): OpeningHours
    {
        $cacheKey = $this->createCacheKeyFromArray(
            ['week', $serviceId, $channelId, $date]
        );
Severity: Major
Found in src/Service/Channel/OpeningHoursService.php and 3 other locations - About 1 hr to fix
src/Service/Channel/OpeningHoursService.php on lines 52..62
src/Service/Channel/OpeningHoursService.php on lines 82..92
src/Service/Channel/OpeningHoursService.php on lines 97..107

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 70.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 4 locations. Consider refactoring.
Open

    public function getMonth(int $serviceId, int $channelId, string $date): OpeningHours
    {
        $cacheKey = $this->createCacheKeyFromArray(
            ['month', $serviceId, $channelId, $date]
        );
Severity: Major
Found in src/Service/Channel/OpeningHoursService.php and 3 other locations - About 1 hr to fix
src/Service/Channel/OpeningHoursService.php on lines 52..62
src/Service/Channel/OpeningHoursService.php on lines 67..77
src/Service/Channel/OpeningHoursService.php on lines 97..107

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 70.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 4 locations. Consider refactoring.
Open

    public function getYear(int $serviceId, int $channelId, string $date): OpeningHours
    {
        $cacheKey = $this->createCacheKeyFromArray(
            ['year', $serviceId, $channelId, $date]
        );
Severity: Major
Found in src/Service/Channel/OpeningHoursService.php and 3 other locations - About 1 hr to fix
src/Service/Channel/OpeningHoursService.php on lines 52..62
src/Service/Channel/OpeningHoursService.php on lines 67..77
src/Service/Channel/OpeningHoursService.php on lines 82..92

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 70.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 4 locations. Consider refactoring.
Open

    public function getDay(int $serviceId, int $channelId, string $date): OpeningHours
    {
        $cacheKey = $this->createCacheKeyFromArray(
            ['day', $serviceId, $channelId, $date]
        );
Severity: Major
Found in src/Service/Channel/OpeningHoursService.php and 3 other locations - About 1 hr to fix
src/Service/Channel/OpeningHoursService.php on lines 67..77
src/Service/Channel/OpeningHoursService.php on lines 82..92
src/Service/Channel/OpeningHoursService.php on lines 97..107

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 70.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 4 locations. Consider refactoring.
Open

    public function getMonth(int $serviceId, int $channelId, string $date): string
    {
        $cacheKey = $this->createCacheKeyFromArray(
            ['month', $serviceId, $channelId, $date]
        );
Severity: Major
Found in src/Service/Channel/OpeningHoursHtmlService.php and 3 other locations - About 1 hr to fix
src/Service/Channel/OpeningHoursHtmlService.php on lines 49..59
src/Service/Channel/OpeningHoursHtmlService.php on lines 64..74
src/Service/Channel/OpeningHoursHtmlService.php on lines 94..104

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 67.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 4 locations. Consider refactoring.
Open

    public function getDay(int $serviceId, int $channelId, string $date): string
    {
        $cacheKey = $this->createCacheKeyFromArray(
            ['day', $serviceId, $channelId, $date]
        );
Severity: Major
Found in src/Service/Channel/OpeningHoursHtmlService.php and 3 other locations - About 1 hr to fix
src/Service/Channel/OpeningHoursHtmlService.php on lines 64..74
src/Service/Channel/OpeningHoursHtmlService.php on lines 79..89
src/Service/Channel/OpeningHoursHtmlService.php on lines 94..104

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 67.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 4 locations. Consider refactoring.
Open

    public function getYear(int $serviceId, int $channelId, string $date): string
    {
        $cacheKey = $this->createCacheKeyFromArray(
            ['year', $serviceId, $channelId, $date]
        );
Severity: Major
Found in src/Service/Channel/OpeningHoursHtmlService.php and 3 other locations - About 1 hr to fix
src/Service/Channel/OpeningHoursHtmlService.php on lines 49..59
src/Service/Channel/OpeningHoursHtmlService.php on lines 64..74
src/Service/Channel/OpeningHoursHtmlService.php on lines 79..89

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 67.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 3 locations. Consider refactoring.
Open

<?php

declare(strict_types=1);

namespace StadGent\Services\OpeningHours\Exception;
Severity: Major
Found in src/Exception/NotFoundException.php and 2 other locations - About 1 hr to fix
src/Exception/ChannelNotFoundException.php on lines 1..29
src/Exception/ServiceNotFoundException.php on lines 1..29

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 67.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 3 locations. Consider refactoring.
Open

<?php

declare(strict_types=1);

namespace StadGent\Services\OpeningHours\Exception;
Severity: Major
Found in src/Exception/ChannelNotFoundException.php and 2 other locations - About 1 hr to fix
src/Exception/NotFoundException.php on lines 1..29
src/Exception/ServiceNotFoundException.php on lines 1..29

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 67.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 3 locations. Consider refactoring.
Open

<?php

declare(strict_types=1);

namespace StadGent\Services\OpeningHours\Exception;
Severity: Major
Found in src/Exception/ServiceNotFoundException.php and 2 other locations - About 1 hr to fix
src/Exception/ChannelNotFoundException.php on lines 1..29
src/Exception/NotFoundException.php on lines 1..29

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 67.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 4 locations. Consider refactoring.
Open

    public function getWeek(int $serviceId, int $channelId, string $date): string
    {
        $cacheKey = $this->createCacheKeyFromArray(
            ['week', $serviceId, $channelId, $date]
        );
Severity: Major
Found in src/Service/Channel/OpeningHoursHtmlService.php and 3 other locations - About 1 hr to fix
src/Service/Channel/OpeningHoursHtmlService.php on lines 49..59
src/Service/Channel/OpeningHoursHtmlService.php on lines 79..89
src/Service/Channel/OpeningHoursHtmlService.php on lines 94..104

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 67.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 8 locations. Consider refactoring.
Open

<?php

declare(strict_types=1);

namespace StadGent\Services\OpeningHours\Request\Channel;
Severity: Major
Found in src/Request/Channel/OpeningHoursWeekRequest.php and 7 other locations - About 55 mins to fix
src/Request/Channel/OpeningHoursDayHtmlRequest.php on lines 1..32
src/Request/Channel/OpeningHoursDayRequest.php on lines 1..32
src/Request/Channel/OpeningHoursMonthHtmlRequest.php on lines 1..32
src/Request/Channel/OpeningHoursMonthRequest.php on lines 1..32
src/Request/Channel/OpeningHoursWeekHtmlRequest.php on lines 1..32
src/Request/Channel/OpeningHoursYearHtmlRequest.php on lines 1..32
src/Request/Channel/OpeningHoursYearRequest.php on lines 1..32

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 64.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 8 locations. Consider refactoring.
Open

<?php

declare(strict_types=1);

namespace StadGent\Services\OpeningHours\Request\Channel;
Severity: Major
Found in src/Request/Channel/OpeningHoursDayHtmlRequest.php and 7 other locations - About 55 mins to fix
src/Request/Channel/OpeningHoursDayRequest.php on lines 1..32
src/Request/Channel/OpeningHoursMonthHtmlRequest.php on lines 1..32
src/Request/Channel/OpeningHoursMonthRequest.php on lines 1..32
src/Request/Channel/OpeningHoursWeekHtmlRequest.php on lines 1..32
src/Request/Channel/OpeningHoursWeekRequest.php on lines 1..32
src/Request/Channel/OpeningHoursYearHtmlRequest.php on lines 1..32
src/Request/Channel/OpeningHoursYearRequest.php on lines 1..32

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 64.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 8 locations. Consider refactoring.
Open

<?php

declare(strict_types=1);

namespace StadGent\Services\OpeningHours\Request\Channel;
Severity: Major
Found in src/Request/Channel/OpeningHoursMonthRequest.php and 7 other locations - About 55 mins to fix
src/Request/Channel/OpeningHoursDayHtmlRequest.php on lines 1..32
src/Request/Channel/OpeningHoursDayRequest.php on lines 1..32
src/Request/Channel/OpeningHoursMonthHtmlRequest.php on lines 1..32
src/Request/Channel/OpeningHoursWeekHtmlRequest.php on lines 1..32
src/Request/Channel/OpeningHoursWeekRequest.php on lines 1..32
src/Request/Channel/OpeningHoursYearHtmlRequest.php on lines 1..32
src/Request/Channel/OpeningHoursYearRequest.php on lines 1..32

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 64.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 8 locations. Consider refactoring.
Open

<?php

declare(strict_types=1);

namespace StadGent\Services\OpeningHours\Request\Channel;
Severity: Major
Found in src/Request/Channel/OpeningHoursYearRequest.php and 7 other locations - About 55 mins to fix
src/Request/Channel/OpeningHoursDayHtmlRequest.php on lines 1..32
src/Request/Channel/OpeningHoursDayRequest.php on lines 1..32
src/Request/Channel/OpeningHoursMonthHtmlRequest.php on lines 1..32
src/Request/Channel/OpeningHoursMonthRequest.php on lines 1..32
src/Request/Channel/OpeningHoursWeekHtmlRequest.php on lines 1..32
src/Request/Channel/OpeningHoursWeekRequest.php on lines 1..32
src/Request/Channel/OpeningHoursYearHtmlRequest.php on lines 1..32

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 64.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 8 locations. Consider refactoring.
Open

<?php

declare(strict_types=1);

namespace StadGent\Services\OpeningHours\Request\Channel;
Severity: Major
Found in src/Request/Channel/OpeningHoursMonthHtmlRequest.php and 7 other locations - About 55 mins to fix
src/Request/Channel/OpeningHoursDayHtmlRequest.php on lines 1..32
src/Request/Channel/OpeningHoursDayRequest.php on lines 1..32
src/Request/Channel/OpeningHoursMonthRequest.php on lines 1..32
src/Request/Channel/OpeningHoursWeekHtmlRequest.php on lines 1..32
src/Request/Channel/OpeningHoursWeekRequest.php on lines 1..32
src/Request/Channel/OpeningHoursYearHtmlRequest.php on lines 1..32
src/Request/Channel/OpeningHoursYearRequest.php on lines 1..32

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 64.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 8 locations. Consider refactoring.
Open

<?php

declare(strict_types=1);

namespace StadGent\Services\OpeningHours\Request\Channel;
Severity: Major
Found in src/Request/Channel/OpeningHoursWeekHtmlRequest.php and 7 other locations - About 55 mins to fix
src/Request/Channel/OpeningHoursDayHtmlRequest.php on lines 1..32
src/Request/Channel/OpeningHoursDayRequest.php on lines 1..32
src/Request/Channel/OpeningHoursMonthHtmlRequest.php on lines 1..32
src/Request/Channel/OpeningHoursMonthRequest.php on lines 1..32
src/Request/Channel/OpeningHoursWeekRequest.php on lines 1..32
src/Request/Channel/OpeningHoursYearHtmlRequest.php on lines 1..32
src/Request/Channel/OpeningHoursYearRequest.php on lines 1..32

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 64.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 8 locations. Consider refactoring.
Open

<?php

declare(strict_types=1);

namespace StadGent\Services\OpeningHours\Request\Channel;
Severity: Major
Found in src/Request/Channel/OpeningHoursDayRequest.php and 7 other locations - About 55 mins to fix
src/Request/Channel/OpeningHoursDayHtmlRequest.php on lines 1..32
src/Request/Channel/OpeningHoursMonthHtmlRequest.php on lines 1..32
src/Request/Channel/OpeningHoursMonthRequest.php on lines 1..32
src/Request/Channel/OpeningHoursWeekHtmlRequest.php on lines 1..32
src/Request/Channel/OpeningHoursWeekRequest.php on lines 1..32
src/Request/Channel/OpeningHoursYearHtmlRequest.php on lines 1..32
src/Request/Channel/OpeningHoursYearRequest.php on lines 1..32

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 64.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 8 locations. Consider refactoring.
Open

<?php

declare(strict_types=1);

namespace StadGent\Services\OpeningHours\Request\Channel;
Severity: Major
Found in src/Request/Channel/OpeningHoursYearHtmlRequest.php and 7 other locations - About 55 mins to fix
src/Request/Channel/OpeningHoursDayHtmlRequest.php on lines 1..32
src/Request/Channel/OpeningHoursDayRequest.php on lines 1..32
src/Request/Channel/OpeningHoursMonthHtmlRequest.php on lines 1..32
src/Request/Channel/OpeningHoursMonthRequest.php on lines 1..32
src/Request/Channel/OpeningHoursWeekHtmlRequest.php on lines 1..32
src/Request/Channel/OpeningHoursWeekRequest.php on lines 1..32
src/Request/Channel/OpeningHoursYearRequest.php on lines 1..32

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 64.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 4 locations. Consider refactoring.
Open

<?php

declare(strict_types=1);

namespace StadGent\Services\OpeningHours\Uri\Channel;
Severity: Major
Found in src/Uri/Channel/OpeningHoursMonthUri.php and 3 other locations - About 40 mins to fix
src/Uri/Channel/OpeningHoursDayUri.php on lines 1..35
src/Uri/Channel/OpeningHoursWeekUri.php on lines 1..35
src/Uri/Channel/OpeningHoursYearUri.php on lines 1..35

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 59.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Severity
Category
Status
Source
Language