diff options
author | n1t0r <git@n1t0r.com> | 2023-04-15 21:27:48 +1000 |
---|---|---|
committer | n1t0r <git@n1t0r.com> | 2023-04-15 21:27:48 +1000 |
commit | 8feb6b48c79e947f6635e35aed13fffebab5a2aa (patch) | |
tree | 7200efc14dc2b01b59fb5c1a1b65456e883114b1 | |
parent | 5352244d0166d34620897eeae0efa71801f48fae (diff) | |
download | steady-8feb6b48c79e947f6635e35aed13fffebab5a2aa.tar.gz steady-8feb6b48c79e947f6635e35aed13fffebab5a2aa.tar.bz2 steady-8feb6b48c79e947f6635e35aed13fffebab5a2aa.zip |
Fix empty tag panic if not registered.
-rw-r--r-- | queue.go | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -97,7 +97,7 @@ func (q *Queue[K]) init() { // return. func (q *Queue[K]) Push(item Item[K]) (ok bool) { q.once.Do(q.init) - if t, ok1 := item.(Tagged); ok1 { + if t, ok1 := item.(Tagged); ok1 && t.Tag() != "" { tc := q.tagCount[t.Tag()] if tc == nil { // Item is tagged but the tag doesn't exist. Programmer error; this |