diff --git a/src/Service/DataSynchronizationService.php b/src/Service/DataSynchronizationService.php index e2b6b14f..c6eb95ed 100644 --- a/src/Service/DataSynchronizationService.php +++ b/src/Service/DataSynchronizationService.php @@ -5,7 +5,6 @@ use App\Entity\Account; use App\Entity\Client; use App\Entity\DataProvider; -use App\Entity\Epic; use App\Entity\Invoice; use App\Entity\Issue; use App\Entity\Project; diff --git a/src/Service/InvoicingRateReportService.php b/src/Service/InvoicingRateReportService.php index 761b27bc..afb7cd3d 100644 --- a/src/Service/InvoicingRateReportService.php +++ b/src/Service/InvoicingRateReportService.php @@ -11,6 +11,8 @@ class InvoicingRateReportService { + private const SECONDS_TO_HOURS = 1 / 3600; + public function __construct( private readonly WorkerRepository $workerRepository, private readonly WorklogRepository $worklogRepository, @@ -88,7 +90,7 @@ public function getInvoicingRateReport( // Tally up logged hours in gathered worklogs for current period $loggedHours = 0; foreach ($worklogs as $worklog) { - $loggedHours += ($worklog->getTimeSpentSeconds() / 60 / 60); + $loggedHours += ($worklog->getTimeSpentSeconds() * self::SECONDS_TO_HOURS); } // Tally up billable logged hours in gathered worklogs for current period