Commit 634f8e96 authored by Stan Hu's avatar Stan Hu

Gracefully handle undefined data in getTreeEntries()

parent 265d461a
......@@ -4,6 +4,11 @@ import { generateTreeList } from '../store/utils';
// eslint-disable-next-line no-restricted-globals
self.addEventListener('message', e => {
const { data } = e;
if (data === undefined) {
return;
}
const { treeEntries, tree } = generateTreeList(data);
// eslint-disable-next-line no-restricted-globals
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment