Appease linter.

This commit is contained in:
Jason Reed
2020-06-30 11:13:10 -04:00
parent 94d230308c
commit ec45db3bc3
3 changed files with 8 additions and 9 deletions

View File

@@ -388,13 +388,13 @@ export class InterfaceManager extends DisposableObject {
pageNumber: number
): Promise<void> {
if (this._displayedQuery === undefined) {
throw new Error(`Trying to show interpreted results but displayed query was undefined`);
throw new Error('Trying to show interpreted results but displayed query was undefined');
}
if (this._interpretation === undefined) {
throw new Error(`Trying to show interpreted results but interpretation was undefined`);
throw new Error('Trying to show interpreted results but interpretation was undefined');
}
if (this._interpretation.sarif.runs[0].results === undefined) {
throw new Error(`Trying to show interpreted results but results were undefined`);
throw new Error('Trying to show interpreted results but results were undefined');
}
const resultSetSchemas = await this.getResultSetSchemas(this._displayedQuery);
@@ -524,7 +524,7 @@ export class InterfaceManager extends DisposableObject {
INTERPRETED_RESULTS_PAGE_SIZE * pageNumber,
INTERPRETED_RESULTS_PAGE_SIZE * (pageNumber + 1)
)
}
};
}
if (this._interpretation === undefined) {
@@ -537,7 +537,7 @@ export class InterfaceManager extends DisposableObject {
return {
...interp,
sarif: { ...interp.sarif, runs: [getPageOfRun(interp.sarif.runs[0])] },
}
};
}
private async interpretResultsInfo(

View File

@@ -117,7 +117,7 @@ export class ResultTables
* true as long as the result sets we're given are marked to permit it.
*/
paginationEnabled(): boolean {
return this.paginationAllowed()
return this.paginationAllowed();
}
constructor(props: ResultTablesProps) {

View File

@@ -197,7 +197,7 @@ class App extends React.Component<{}, ResultsViewState> {
this.loadResults();
break;
case 'showInterpretedPage':
const resultsInfo: ResultsInfo = {
this.updateStateWithNewResultsInfo({
resultsPath: '', // FIXME: Not used for interpreted, refactor so this is not needed
parsedResultSets: {
t: 'ExtensionParsed',
@@ -218,8 +218,7 @@ class App extends React.Component<{}, ResultsViewState> {
interpretation: msg.interpretation,
shouldKeepOldResultsWhileRendering: true,
metadata: msg.metadata,
};
this.updateStateWithNewResultsInfo(resultsInfo);
});
this.loadResults();
break;
case 'resultsUpdating':