aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--server/sonar-web/src/main/js/apps/projectQualityGate/App.tsx8
-rw-r--r--server/sonar-web/src/main/js/apps/projects/filters/Filter.tsx2
-rw-r--r--server/sonar-web/src/main/js/apps/settings/components/pullRequestDecorationBinding/PRDecorationBinding.tsx2
3 files changed, 8 insertions, 4 deletions
diff --git a/server/sonar-web/src/main/js/apps/projectQualityGate/App.tsx b/server/sonar-web/src/main/js/apps/projectQualityGate/App.tsx
index 42e67969a5c..2d16c895ac0 100644
--- a/server/sonar-web/src/main/js/apps/projectQualityGate/App.tsx
+++ b/server/sonar-web/src/main/js/apps/projectQualityGate/App.tsx
@@ -74,9 +74,13 @@ export default class App extends React.PureComponent<Props> {
fetchQualityGates({ organization: component.organization }),
getGateForProject({ organization: component.organization, project: component.key })
]).then(
- ([{ qualitygates: allGates }, gate]) => {
+ ([qualityGateList, gate]) => {
if (this.mounted) {
- this.setState({ allGates, gate, loading: false });
+ this.setState({
+ allGates: qualityGateList?.qualitygates,
+ gate,
+ loading: false
+ });
}
},
() => {
diff --git a/server/sonar-web/src/main/js/apps/projects/filters/Filter.tsx b/server/sonar-web/src/main/js/apps/projects/filters/Filter.tsx
index 9d44317e85b..3b02d76077f 100644
--- a/server/sonar-web/src/main/js/apps/projects/filters/Filter.tsx
+++ b/server/sonar-web/src/main/js/apps/projects/filters/Filter.tsx
@@ -39,7 +39,7 @@ interface Props {
optionClassName?: string;
organization?: { key: string };
- getFacetValueForOption?: (facet: Facet, option: Option) => void;
+ getFacetValueForOption?: (facet: Facet, option: Option) => number;
halfWidth?: boolean;
highlightUnder?: number;
diff --git a/server/sonar-web/src/main/js/apps/settings/components/pullRequestDecorationBinding/PRDecorationBinding.tsx b/server/sonar-web/src/main/js/apps/settings/components/pullRequestDecorationBinding/PRDecorationBinding.tsx
index e9a6f969069..8d7ac7492bd 100644
--- a/server/sonar-web/src/main/js/apps/settings/components/pullRequestDecorationBinding/PRDecorationBinding.tsx
+++ b/server/sonar-web/src/main/js/apps/settings/components/pullRequestDecorationBinding/PRDecorationBinding.tsx
@@ -81,7 +81,7 @@ export default class PRDecorationBinding extends React.PureComponent<Props, Stat
const newFormData = originalData || formData;
return {
formData: newFormData,
- instances,
+ instances: instances || [],
isValid: this.validateForm(newFormData),
loading: false,
originalData