Skip to content

Commit

Permalink
[bugfix] Allow datasets without mutations
Browse files Browse the repository at this point in the history
See #1474 for more context
  • Loading branch information
jameshadfield committed Feb 23, 2022
1 parent 5f36a94 commit eddc395
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/util/treeMiscHelpers.js
Original file line number Diff line number Diff line change
Expand Up @@ -173,6 +173,9 @@ export const getSeqChanges = (fromNode) => {
*/
export const categoriseMutations = (mutations, observedMutations, seqChangesToRoot) => {
const categorisedMutations = {};
if (typeof mutations !== "object") {
return categorisedMutations;
}
for (const gene of Object.keys(mutations)) {
const categories = { unique: [], homoplasies: [], gaps: [], reversionsToRoot: []};
const isNuc = gene==="nuc";
Expand Down

0 comments on commit eddc395

Please sign in to comment.