DB: fix double remove. See #315