diff options
5 files changed, 5 insertions, 6 deletions
diff --git a/server/sonar-web/src/main/js/app/components/nav/component/ComponentNavBgTaskNotif.tsx b/server/sonar-web/src/main/js/app/components/nav/component/ComponentNavBgTaskNotif.tsx index 732b7ea3170..5b906826ecc 100644 --- a/server/sonar-web/src/main/js/app/components/nav/component/ComponentNavBgTaskNotif.tsx +++ b/server/sonar-web/src/main/js/app/components/nav/component/ComponentNavBgTaskNotif.tsx @@ -44,7 +44,7 @@ export default class ComponentNavBgTaskNotif extends React.PureComponent<Props> renderMessage(messageKey: string) { const { component } = this.props; const canSeeBackgroundTasks = - component.configuration != undefined && component.configuration.showBackgroundTasks; + component.configuration !== undefined && component.configuration.showBackgroundTasks; const bgTaskUrl = getComponentBackgroundTaskUrl(component.key); if (canSeeBackgroundTasks) { diff --git a/server/sonar-web/src/main/js/apps/system/components/App.tsx b/server/sonar-web/src/main/js/apps/system/components/App.tsx index c6d333563ab..2211ed17dd5 100644 --- a/server/sonar-web/src/main/js/apps/system/components/App.tsx +++ b/server/sonar-web/src/main/js/apps/system/components/App.tsx @@ -123,7 +123,7 @@ export default class App extends React.PureComponent<Props, State> { loading={loading} isCluster={isCluster(sysInfoData)} logLevel={getSystemLogsLevel(sysInfoData)} - showActions={sysInfoData != undefined} + showActions={sysInfoData !== undefined} onLogLevelChange={this.fetchSysInfo} /> {this.renderSysInfo()} diff --git a/server/sonar-web/src/main/js/components/SourceViewer/SourceViewerBase.js b/server/sonar-web/src/main/js/components/SourceViewer/SourceViewerBase.js index 2cfee3e3c05..3b2b9593366 100644 --- a/server/sonar-web/src/main/js/components/SourceViewer/SourceViewerBase.js +++ b/server/sonar-web/src/main/js/components/SourceViewer/SourceViewerBase.js @@ -689,8 +689,6 @@ export default class SourceViewerBase extends React.PureComponent { 'source-duplications-expanded': this.state.displayDuplications }); - const displaySources = !notAccessible && !sourceRemoved; - return ( <div className={className} ref={node => (this.node = node)}> <SourceViewerHeader @@ -703,7 +701,7 @@ export default class SourceViewerBase extends React.PureComponent { {translate('code_viewer.no_source_code_displayed_due_to_source_removed')} </div> )} - {displaySources && sources != null && this.renderCode(sources)} + {!sourceRemoved && sources != null && this.renderCode(sources)} </div> ); } diff --git a/server/sonar-web/src/main/js/components/issue/Issue.js b/server/sonar-web/src/main/js/components/issue/Issue.js index 6637f8e87dc..11ff2e01a19 100644 --- a/server/sonar-web/src/main/js/components/issue/Issue.js +++ b/server/sonar-web/src/main/js/components/issue/Issue.js @@ -111,6 +111,7 @@ export default class Issue extends React.PureComponent { this.props.onCheck(this.props.issue.key); return false; } + return undefined; }); } diff --git a/server/sonar-web/src/main/js/helpers/dates.ts b/server/sonar-web/src/main/js/helpers/dates.ts index 3bba40df67e..571e73b20ae 100644 --- a/server/sonar-web/src/main/js/helpers/dates.ts +++ b/server/sonar-web/src/main/js/helpers/dates.ts @@ -41,7 +41,7 @@ export function parseDate(rawDate: ParsableDate): Date { export function toShortNotSoISOString(rawDate: ParsableDate): string { const date = parseDate(rawDate); - return date.getFullYear() + '-' + pad(date.getMonth() + 1) + '-' + pad(date.getDate()); + return `${date.getFullYear()}-${pad(date.getMonth() + 1)}-${pad(date.getDate())}`; } export function toNotSoISOString(rawDate: ParsableDate): string { |