debian-mirror-gitlab/app/assets/javascripts/diffs/utils/diff_line.js

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

11 lines
204 B
JavaScript
Raw Normal View History

2021-12-11 22:18:48 +05:30
export function pickDirection({ line, code } = {}) {
const { left, right } = line;
let direction = left || right;
if (right?.line_code === code) {
direction = right;
}
return direction;
}