fixed various archive bugs