Skip to content

Commit

Permalink
fix: skip non-existing models
Browse files Browse the repository at this point in the history
  • Loading branch information
maartenbreddels authored and martinRenou committed Sep 13, 2021
1 parent 4f3f57b commit e1c5ab1
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions widgetsnbextension/src/manager.js
Original file line number Diff line number Diff line change
Expand Up @@ -231,8 +231,10 @@ export class WidgetManager extends ManagerBase {
if (widget_output) {
var model_id = widget_output.data[MIME_TYPE].model_id;
var model = await this.get_model(model_id);
var bundle = await model.generateMimeBundle();
_.extend(widget_output.data, bundle);
if (model) {
var bundle = await model.generateMimeBundle();
_.extend(widget_output.data, bundle);
}
}
})
);
Expand Down

0 comments on commit e1c5ab1

Please sign in to comment.