Show More
@@ -117,7 +117,7 b' def display(*objs, **kwargs):' | |||
|
117 | 117 | |
|
118 | 118 | # If _ipython_display_ is defined, use that to display this object. If |
|
119 | 119 | # it returns NotImplemented, use the _repr_ logic (default). |
|
120 |
if not hasattr(obj, '_ipython_display_') or obj._ipython_display_(**kwargs) |
|
|
120 | if not hasattr(obj, '_ipython_display_') or obj._ipython_display_(**kwargs) is NotImplemented: | |
|
121 | 121 | if raw: |
|
122 | 122 | publish_display_data('display', obj, metadata) |
|
123 | 123 | else: |
@@ -243,7 +243,7 b' class DisplayHook(Configurable):' | |||
|
243 | 243 | if result is not None and not self.quiet(): |
|
244 | 244 | # If _ipython_display_ is defined, use that to display this object. If |
|
245 | 245 | # it returns NotImplemented, use the _repr_ logic (default). |
|
246 |
if not hasattr(result, '_ipython_display_') or result._ipython_display_() |
|
|
246 | if not hasattr(result, '_ipython_display_') or result._ipython_display_() is NotImplemented: | |
|
247 | 247 | self.start_displayhook() |
|
248 | 248 | self.write_output_prompt() |
|
249 | 249 | format_dict, md_dict = self.compute_format_data(result) |
General Comments 0
You need to be logged in to leave comments.
Login now