mirror of
https://github.com/metabarcoding/obitools4.git
synced 2025-06-29 16:20:46 +00:00
Patch a bug in registering merged taxa
This commit is contained in:
@ -8,7 +8,7 @@ import (
|
||||
// corresponds to the last commit, and not the one when the file will be
|
||||
// commited
|
||||
|
||||
var _Commit = "773e549"
|
||||
var _Commit = "f2e81ad"
|
||||
var _Version = "Release 4.2.0"
|
||||
|
||||
// Version returns the version of the obitools package.
|
||||
|
@ -131,7 +131,7 @@ func loadMergedTable(reader io.Reader, taxonomy *Taxonomy) int {
|
||||
oldtaxid := strings.TrimSpace(record[0])
|
||||
newtaxid := strings.TrimSpace(record[1])
|
||||
|
||||
taxonomy.AddAlias(newtaxid, oldtaxid, false)
|
||||
taxonomy.AddAlias(oldtaxid, newtaxid, false)
|
||||
}
|
||||
|
||||
return n
|
||||
|
@ -151,7 +151,8 @@ func (set *TaxonSet) Alias(id *string, taxon *Taxon) {
|
||||
if original == nil {
|
||||
log.Fatalf("Original taxon %v is not part of taxon set", id)
|
||||
}
|
||||
set.set[id] = taxon.Node
|
||||
|
||||
set.set[id] = original.Node
|
||||
set.nalias++
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user