Hopefully fixes #54 - Indexes not being correctly maintained