Skip to content

Commit

Permalink
Merge branch 'main' into cottsay/devel
Browse files Browse the repository at this point in the history
  • Loading branch information
cottsay committed Sep 10, 2024
2 parents a7445df + 5e0a145 commit 07c5425
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions rosdistro_reviewer/git_lines.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
# Copyright 2024 Open Source Robotics Foundation, Inc.
# Licensed under the Apache License, Version 2.0

import os.path
from typing import Dict
from typing import Iterable
from typing import List
Expand Down Expand Up @@ -84,8 +85,9 @@ def get_added_lines(
for line in hunk:
if line.line_type != unidiff.LINE_TYPE_ADDED:
continue
lines.setdefault(file.path, [])
lines[file.path].append(line.target_line_no)
lines.setdefault(
os.path.normpath(file.path),
[]).append(line.target_line_no)

if not lines:
return None
Expand Down

0 comments on commit 07c5425

Please sign in to comment.