RemovePriceAlert use parameter not edit control

pull/191/head
Simon Roberts 3 years ago
parent aa2e72a20e
commit 5665234db8
No known key found for this signature in database
GPG Key ID: 0F30F99E6B771FD4

@ -477,7 +477,7 @@ func (ct *Cointop) SetPriceAlert(coinName string, operator string, targetPrice f
func (ct *Cointop) RemovePriceAlert(id string) error {
log.Debug("RemovePriceAlert()")
for i, entry := range ct.State.priceAlerts.Entries {
if entry.ID == ct.State.priceAlertEditID {
if entry.ID == id {
ct.State.priceAlerts.Entries = append(ct.State.priceAlerts.Entries[:i], ct.State.priceAlerts.Entries[i+1:]...)
}
}

Loading…
Cancel
Save