fixed archive and complete functions