Skip to content

Commit 40db7e0

Browse files
author
Joshua Parker
committed
Fixed division by zero with running STTR cronjob.
1 parent 351cc4d commit 40db7e0

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

app/routers/cron.router.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -788,7 +788,8 @@
788788
AND stac.creditType = 'I'
789789
AND grade_scale.count_in_gpa = '1'
790790
AND (stac.grade IS NOT NULL OR stac.grade <> '')
791-
GROUP BY stac.stuID,stac.termCode,stac.acadLevelCode");
791+
GROUP BY stac.stuID,stac.termCode,stac.acadLevelCode
792+
HAVING COALESCE(SUM(stac.gradePoints),0) > 0");
792793
$q = $terms->find(function ($data) {
793794
$array = [];
794795
foreach ($data as $d) {

0 commit comments

Comments
 (0)