fixed a bug in how sequences are renamed