@@ -105,7 +105,7 @@ def getData(self) -> Tuple[List[float], List[float]]:
105105 return self .opts ["width" ], self .opts ["y" ]
106106
107107 def update_leading_line (self ) -> None :
108- if self .opts ["width" ] == [] and self .opts ["y" ] == []:
108+ if self .opts ["width" ] is [] and self .opts ["y" ] is []:
109109 self .clear_leading_lines ()
110110 return
111111
@@ -117,7 +117,7 @@ def update_leading_line(self) -> None:
117117
118118 def data_bounds (self , ax : int = 0 , offset : int = 0 ) -> Tuple [np .ndarray , np .ndarray ]:
119119 x , y = self .getData ()
120- if x == [] and y == []:
120+ if x is [] and y is []:
121121 return 0 , 0
122122 if ax == 0 :
123123 sub_range = x [- offset :]
@@ -127,7 +127,7 @@ def data_bounds(self, ax: int = 0, offset: int = 0) -> Tuple[np.ndarray, np.ndar
127127
128128 def data_tick (self , ax : int = 0 ):
129129 x , y = self .getData ()
130- if x == [] and y == []:
130+ if x is [] and y is []:
131131 return 0 , 0
132132 if ax == 0 :
133133 return x [0 ] if len (x ) == 1 else x [1 ] - x [0 ]
@@ -152,7 +152,7 @@ def clear(self):
152152 self .sigPlotChanged .emit ()
153153
154154 def update_leading_line (self ) -> None :
155- if self .opts ["x" ] == [] and self .opts ["height" ] == []:
155+ if self .opts ["x" ] is [] and self .opts ["height" ] is []:
156156 self .clear_leading_lines ()
157157 return
158158
@@ -164,7 +164,7 @@ def update_leading_line(self) -> None:
164164
165165 def data_bounds (self , ax : int = 0 , offset : int = 0 ) -> Tuple [np .ndarray , np .ndarray ]:
166166 x , y = self .getData ()
167- if x == [] and y == []:
167+ if x is [] and y is []:
168168 return 0 , 0
169169 if ax == 0 :
170170 sub_range = x [- offset :]
@@ -174,7 +174,7 @@ def data_bounds(self, ax: int = 0, offset: int = 0) -> Tuple[np.ndarray, np.ndar
174174
175175 def data_tick (self , ax : int = 0 ):
176176 x , y = self .getData ()
177- if x == [] and y == []:
177+ if x is [] and y is []:
178178 return 0 , 0
179179 if ax == 0 :
180180 return x [0 ] if len (x ) == 1 else x [1 ] - x [0 ]
0 commit comments