The VCFRecord.filter function incorrectly returns the first filter repeated for the number of filters, instead of all filters.
/* FILTER */
/// Get FILTER column (nothing in htslib sadly)
@property string filter()
{
const(char)[] ret;
this.unpack(UnpackLevel.Filter);
if (this.line.d.n_flt) {
for(int i; i< this.line.d.n_flt; i++) {
if (i) ret ~= ";";
ret ~= fromStringz(this.vcfheader.hdr.id[BCF_DT_ID][ this.line.d.flt[0] ].key);
}
} else {
ret = ".";
}
return ret.idup;
}
Fix is below:
this should be i |
v
ret ~= fromStringz(this.vcfheader.hdr.id[BCF_DT_ID][ this.line.d.flt[0] ].key);
The
VCFRecord.filterfunction incorrectly returns the first filter repeated for the number of filters, instead of all filters.Fix is below: