Don't copy reftags twice

Fixes #678