feat: quiz and rbac
This commit is contained in:
@@ -39,7 +39,8 @@ type CategoryCount struct {
|
||||
// the table sizes are modest enough that chasing parallelism here
|
||||
// would buy sub-ms wins for added complexity.
|
||||
func (r *StatsRepo) Snapshot(ctx context.Context) (*StatsSnapshot, error) {
|
||||
s := &StatsSnapshot{}
|
||||
// Non-nil so an empty table serialises as [] rather than null.
|
||||
s := &StatsSnapshot{FeedbackByCategory: []CategoryCount{}}
|
||||
sevenAgo := time.Now().Add(-7 * 24 * time.Hour)
|
||||
|
||||
scalars := []struct {
|
||||
|
||||
Reference in New Issue
Block a user