Skip to content

Commit 060dcfd

Browse files
authored
Small fixes for modern flake8. (#484)
Signed-off-by: Chris Lalancette <[email protected]>
1 parent 1dc0e38 commit 060dcfd

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

ament_copyright/ament_copyright/main.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -267,7 +267,7 @@ def add_missing_header(file_descriptors, name, license_, verbose):
267267

268268
def add_copyright_year(file_descriptors, new_years, verbose):
269269
if verbose:
270-
print(f'Adding {",".join(map(str,new_years))} to existing copyright notices:')
270+
print(f'Adding {",".join(map(str, new_years))} to existing copyright notices:')
271271
print()
272272

273273
for path in sorted(file_descriptors.keys()):

ament_copyright/ament_copyright/parser.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -347,7 +347,7 @@ def remove_formatting(text):
347347

348348
# Flat list of sections split on all separators provided
349349
def split_template(sections, separators):
350-
if type(sections) != list:
350+
if not isinstance(sections, list):
351351
return split_template([sections], separators)
352352
elif len(separators) > 1:
353353
return sum([split_template([section], separators[0:1]) for section

0 commit comments

Comments
 (0)