]> git.donarmstrong.com Git - mothur.git/blobdiff - phylotypecommand.cpp
fixed classify.seq error message when flip accnos file was blank. Fixed bug with...
[mothur.git] / phylotypecommand.cpp
index 1d6c391de69c83a86971873577a0df0b21efdbcd..f402f2a8ab15a1808a461d376818d97d98c5c5c7 100644 (file)
@@ -244,13 +244,15 @@ int PhylotypeCommand::execute(){
                                        //make the names compatable with listvector
                                        string name = "";
                                        for (int i = 0; i < names.size(); i++) {  
-                                               if (namefile != "") {   
-                                                       map<string, string>::iterator itNames = namemap.find(names[i]);  //make sure this name is in namefile
-               
-                                                       if (itNames != namemap.end()) {  name += namemap[names[i]] + ",";   } //you found it in namefile
-                                                       else { m->mothurOut(names[i] + " is not in your namefile, please correct."); m->mothurOutEndLine(); exit(1);  }
-                                                       
-                                               }else{   name += names[i] + ",";        }
+                        if (names[i] != "unknown") {
+                            if (namefile != "") {      
+                                map<string, string>::iterator itNames = namemap.find(names[i]);  //make sure this name is in namefile
+                                
+                                if (itNames != namemap.end()) {  name += namemap[names[i]] + ",";   } //you found it in namefile
+                                else { m->mothurOut(names[i] + " is not in your namefile, please correct."); m->mothurOutEndLine(); exit(1);  }
+                                
+                            }else{   name += names[i] + ",";   }
+                        }
                                        }
                                        name = name.substr(0, name.length()-1);  //rip off extra ','