Skip to content

Commit

Permalink
fix: seed demo and user catalog
Browse files Browse the repository at this point in the history
  • Loading branch information
PThorpe92 committed Dec 14, 2024
1 parent 09dec1a commit 7a5a931
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion backend/src/database/user_catalogue.go
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ func (db *DB) GetUserCourses(userId uint, order string, orderBy string, search s
SELECT
m.course_id,
m.user_id,
COUNT(m.id) * 100.0 / cc.total_progress_milestones AS course_progress
COUNT(m.id) * 100.0 / NULLIF(cc.total_progress_milestones, 0) AS course_progress
FROM milestones m
JOIN courses cc ON m.course_id = cc.id
WHERE m.user_id = ? AND cc.deleted_at IS NULL
Expand Down

0 comments on commit 7a5a931

Please sign in to comment.