Skip to content

Commit 9697545

Browse files
dhomeierastrofrog
andcommitted
Simplify conversion
Co-authored-by: Thomas Robitaille <[email protected]>
1 parent ad94478 commit 9697545

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

glue_jupyter/bqplot/common/viewer.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
from ...view import IPyWidgetView
1212
from ...link import on_change
13-
from ...utils import float_or_none, debounced, get_ioloop
13+
from ...utils import debounced, get_ioloop
1414
from .tools import ROIClickAndDrag
1515

1616
__all__ = ['BqplotBaseView']
@@ -116,13 +116,13 @@ def _update_bqplot_limits(self, *args):
116116

117117
if self.state.x_min is not None and self.state.x_max is not None:
118118
with self.scale_x.hold_sync():
119-
self.scale_x.min = float_or_none(self.state.x_min)
120-
self.scale_x.max = float_or_none(self.state.x_max)
119+
self.scale_x.min = float(self.state.x_min)
120+
self.scale_x.max = float(self.state.x_max)
121121

122122
if self.state.y_min is not None and self.state.y_max is not None:
123123
with self.scale_y.hold_sync():
124-
self.scale_y.min = float_or_none(self.state.y_min)
125-
self.scale_y.max = float_or_none(self.state.y_max)
124+
self.scale_y.min = float(self.state.y_min)
125+
self.scale_y.max = float(self.state.y_max)
126126

127127
self._last_limits = (self.state.x_min, self.state.x_max,
128128
self.state.y_min, self.state.y_max)

0 commit comments

Comments
 (0)