magickatt/MultiContextBDDTalk

View on GitHub
backend/src/HistoricalMeteorological/Service/ResponseService.php

Summary

Maintainability
A
0 mins
Test Coverage

Showing 8 of 8 total issues

Avoid using static access to class '\HistoricalMeteorological\Transformer\EntrySummaryTransformer' in method 'createEntryAggregateSummaryCollectionResponse'.
Open

'meta' => EntrySummaryTransformer::transformEntrySummaryToArray($summary),

Avoid using static access to class '\HistoricalMeteorological\Calculator\EntryCollectionSummaryCalculator' in method 'createEntryComparisonSummaryCollectionResponse'.
Open

$summaryComparison = EntryCollectionSummaryCalculator::compareEntryCollections($collection1, $collection2);

Avoid using static access to class '\HistoricalMeteorological\Transformer\EntrySummaryTransformer' in method 'createEntryComparisonSummaryCollectionResponse'.
Open

'meta' => EntrySummaryTransformer::transformEntrySummaryComparisonToArray($summaryComparison),

Avoid using static access to class '\HistoricalMeteorological\Transformer\LocationTransformer' in method 'createLocationResponse'.
Open

return $this->createSingularResponse(LocationTransformer::transformLocationToArray($location), $responseCode);

Avoid using static access to class '\HistoricalMeteorological\Calculator\EntryCollectionSummaryCalculator' in method 'createEntryAggregateSummaryCollectionResponse'.
Open

$summary = EntryCollectionSummaryCalculator::summariseEntryCollection($collection, new EntrySummary());

Avoid unused private methods such as 'createPluralResponse'.
Open

private function createPluralResponse(CollectionInterface $collection, int $responseCode = 200)
{
return new JsonResponse(
[
'data' => $collection->toArray(),

Line exceeds 120 characters; contains 135 characters
Open

'data' => array_map(array(EntryTransformer::class, 'transformEntryToArray'), $collection1->merge($collection2)->toArray()),

Line exceeds 120 characters; contains 122 characters
Open

public function createEntryComparisonSummaryCollectionResponse(EntryComparisonSummaryCollection $comparisonCollection)

There are no issues that match your filters.

Category
Status