summaryrefslogtreecommitdiff
path: root/rddb
diff options
context:
space:
mode:
authorChristian Pointner <equinox@helsinki.at>2016-02-11 15:19:17 (GMT)
committerChristian Pointner <equinox@helsinki.at>2016-02-11 15:19:17 (GMT)
commitd4761d9b12b8c552f9d6fe6c17f8db3b6894ba90 (patch)
tree9ef226d5544051888e3e0fa6fb620f86937edbef /rddb
parent4dbf06dc21143c2fb81855b8d60cacf85f7ece6b (diff)
also include jingle group name in JingleListEntry
Diffstat (limited to 'rddb')
-rw-r--r--rddb/rddb.go7
1 files changed, 4 insertions, 3 deletions
diff --git a/rddb/rddb.go b/rddb/rddb.go
index b2fedf4..e17f3fb 100644
--- a/rddb/rddb.go
+++ b/rddb/rddb.go
@@ -149,6 +149,7 @@ type getShowCartListRequest struct {
}
type JingleListEntry struct {
+ Group string
Description string
ActiveCart int
InactiveCart int
@@ -468,15 +469,15 @@ func (db *DB) getJingleList(username string) (result getJingleListResult) {
result.jingles = make(map[string]JingleListEntry)
for rows.Next() {
var jingle JingleListEntry
- var name, params string
+ var params string
- if result.err = rows.Scan(&name, &params, &jingle.ActiveCart, &jingle.InactiveCart, &jingle.Description); result.err != nil {
+ if result.err = rows.Scan(&jingle.Group, &params, &jingle.ActiveCart, &jingle.InactiveCart, &jingle.Description); result.err != nil {
return
}
if params[0] != 'J' {
continue
}
- result.jingles[name] = jingle
+ result.jingles[jingle.Group] = jingle
}
result.err = rows.Err()
return