Skip to content

Commit

Permalink
Merge pull request #768 from SSWConsulting/fix-custom-rule-highlights
Browse files Browse the repository at this point in the history
Fixed custom rule highlights incorrect column
  • Loading branch information
zacharykeeping authored Nov 15, 2023
2 parents c5c3341 + c1759da commit 05701aa
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions docker/customHtmlRules.js
Original file line number Diff line number Diff line change
Expand Up @@ -71,11 +71,12 @@ exports.addCustomHtmlRule = async (apiToken, url) => {

// Make sure the character has space and is not part of a long single string
if (pageContent.indexOf(' ') >= 0) {
const col = event.col + contentIndex;
if (contentIndex >= 0) {
reporter.warn(
"Incorrect Scrum term: '" + i + "'.",
event.line,
event.col,
col,
self,
event.raw
);
Expand Down Expand Up @@ -479,10 +480,11 @@ exports.addCustomHtmlRule = async (apiToken, url) => {
// Make sure the character has space and is not part of a long single string
if (pageContent.indexOf(' ') >= 0) {
if (contentIndex >= 0) {
const col = event.col + contentIndex;
reporter.warn(
"Incorrect terms: '" + i + "'.",
event.line,
event.col,
col,
self,
event.raw
);
Expand Down

0 comments on commit 05701aa

Please sign in to comment.