Skip to content

Commit ce18465

Browse files
authored
fixed api url in example plugin (#70934)
This PR fixes a API URL used in the Alerting Example plugin which was broken when the Api Endpoint was migrated to it's new location
1 parent d43c460 commit ce18465

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

examples/alerting_example/public/components/view_alert.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,10 +49,10 @@ export const ViewAlertPage = withRouter(({ http, id }: Props) => {
4949

5050
useEffect(() => {
5151
if (!alert) {
52-
http.get(`${BASE_ALERT_API_PATH}/${id}`).then(setAlert);
52+
http.get(`${BASE_ALERT_API_PATH}/alert/${id}`).then(setAlert);
5353
}
5454
if (!alertState) {
55-
http.get(`${BASE_ALERT_API_PATH}/${id}/state`).then(setAlertState);
55+
http.get(`${BASE_ALERT_API_PATH}/alert/${id}/state`).then(setAlertState);
5656
}
5757
}, [alert, alertState, http, id]);
5858

examples/alerting_example/public/components/view_astros_alert.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,10 +55,10 @@ export const ViewPeopleInSpaceAlertPage = withRouter(({ http, id }: Props) => {
5555

5656
useEffect(() => {
5757
if (!alert) {
58-
http.get(`${BASE_ALERT_API_PATH}/${id}`).then(setAlert);
58+
http.get(`${BASE_ALERT_API_PATH}/alert/${id}`).then(setAlert);
5959
}
6060
if (!alertState) {
61-
http.get(`${BASE_ALERT_API_PATH}/${id}/state`).then(setAlertState);
61+
http.get(`${BASE_ALERT_API_PATH}/alert/${id}/state`).then(setAlertState);
6262
}
6363
}, [alert, alertState, http, id]);
6464

0 commit comments

Comments
 (0)