Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -324,6 +324,15 @@
if (!guards.every(x=>x=='istrue')) {
lines[i] = null;
}

if (lines[i] !== null && lines[i]!.startsWith('@DemoSource')) {

Check warning on line 328 in base/src/main/resources/META-INF/resources/frontend/code-viewer.ts

View check run for this annotation

SonarQubeCloud / SonarCloud Code Analysis

Prefer using an optional chain expression instead, as it's more concise and easier to read.

See more on https://sonarcloud.io/project/issues?id=FlowingCode_CommonsDemo&issues=AZ3e_XF0UEm0F9tno_uS&open=AZ3e_XF0UEm0F9tno_uS&pullRequest=158

Check warning on line 328 in base/src/main/resources/META-INF/resources/frontend/code-viewer.ts

View check run for this annotation

SonarQubeCloud / SonarCloud Code Analysis

This assertion is unnecessary since it does not change the type of the expression.

See more on https://sonarcloud.io/project/issues?id=FlowingCode_CommonsDemo&issues=AZ3e_XF0UEm0F9tno_uT&open=AZ3e_XF0UEm0F9tno_uT&pullRequest=158
let open = lines[i]!.includes('(');

Check warning on line 329 in base/src/main/resources/META-INF/resources/frontend/code-viewer.ts

View check run for this annotation

SonarQubeCloud / SonarCloud Code Analysis

This assertion is unnecessary since it does not change the type of the expression.

See more on https://sonarcloud.io/project/issues?id=FlowingCode_CommonsDemo&issues=AZ3e_XF0UEm0F9tno_uU&open=AZ3e_XF0UEm0F9tno_uU&pullRequest=158
do {
open &&= !(lines[i] || '').includes(')');
lines[i++] = null;
} while (open && i < lines.length);
i--;
}
Comment thread
coderabbitai[bot] marked this conversation as resolved.
}

return lines.filter(line=>line!==null)
Expand All @@ -332,7 +341,6 @@
!line.match("//\\s*hide-source(\\s|$)")
&& !line.startsWith('@Route')
&& !line.startsWith('@PageTitle')
&& !line.startsWith('@DemoSource')
&& !line.startsWith('@SuppressWarnings')
&& !line.startsWith('@Ignore')
&& !line.startsWith('package ')
Expand Down
Loading