client/tags: fix crash without exported tags

This commit is contained in:
rr- 2016-06-03 21:37:15 +02:00
parent 73feba4b77
commit aa95afb989

View file

@ -78,8 +78,10 @@ function refreshExport() {
_categories = new Map();
reject(error);
}
_tags = _tagsToMap(response.body.tags);
_categories = _tagCategoriesToMap(response.body.categories);
_tags = _tagsToMap(
response.body ? response.body.tags : []);
_categories = _tagCategoriesToMap(
response.body ? response.body.categories : []);
_refreshStylesheet();
resolve();
});