fix bogus breakpoint position; fixes #39665

This commit is contained in:
Andre Weinand
2017-12-06 15:55:31 +01:00
parent 1738c3e6d0
commit 8e8f4b00bc
3 changed files with 42 additions and 19 deletions

View File

@@ -111,10 +111,8 @@ export class MainThreadDebugService implements MainThreadDebugServiceShape {
condition: sbp.condition,
hitCondition: bp.hitCondition,
sourceUriStr: sbp.uri.toString(),
location: {
line: sbp.lineNumber,
character: sbp.column
}
line: sbp.lineNumber > 0 ? sbp.lineNumber - 1 : 0,
character: (typeof sbp.column === 'number' && sbp.column > 0) ? sbp.column - 1 : 0
};
}
});