dbReadProfile
finds filters by matching on filter.id
in the database, but dbAddRuleFilter
stores the ruleId in filter.rule
#255
Labels
bug
Something isn't working
When using
--import-data
(and possible other code paths leading todbAddRuleFilter
), the rule id this filter belongs to is stored in therule
field of thefilter
table:ical-relay/pkg/datastore/database.go
Lines 445 to 447 in ea4ce94
However, when retrieving a rule, only filters where the
id
of the filter in the database matches therule
are returned:ical-relay/pkg/datastore/database.go
Lines 205 to 206 in ea4ce94
This mismatch causes at least
--import-data
to fail. Simply changing theSELECT
statement to match onrule = $1
instead works, but I'm unsure if this doesn't break other parts of the codebase which store the rule id in theid
field offilter
.The text was updated successfully, but these errors were encountered: