Skip to content

Commit ee7b126

Browse files
authored
Small fix for modern flake8. (ros-visualization#289)
Make sure to use isinstance. Signed-off-by: Chris Lalancette <clalancette@gmail.com>
1 parent abaa07d commit ee7b126

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

qt_dotgraph/src/qt_dotgraph/pydotfactory.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -176,7 +176,7 @@ def add_edge_to_graph(
176176

177177
def create_dot(self, graph):
178178
dot = graph.create_dot()
179-
if type(dot) != str:
179+
if not isinstance(dot, str):
180180
dot = dot.decode()
181181
# sadly pydot generates line wraps cutting between numbers
182182
return dot.replace('\\%s' % os.linesep, '').replace('\\\n', '')

0 commit comments

Comments
 (0)