Skip to content

Commit b16c5e9

Browse files
committed
handle eagle eye axios failure gracefully
1 parent 2366245 commit b16c5e9

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

backend/src/services/eagleEyeContentService.ts

+7-3
Original file line numberDiff line numberDiff line change
@@ -175,10 +175,14 @@ export default class EagleEyeContentService extends LoggerBase {
175175
},
176176
}
177177

178-
console.log('Eagle Eye search config')
179-
console.log(config)
178+
let response
180179

181-
const response = await axios(config)
180+
try {
181+
response = await axios(config)
182+
} catch (error) {
183+
this.log.error("Error while fetching eagle eye content", error, config)
184+
return []
185+
}
182186

183187
const interacted = (
184188
await this.query({

0 commit comments

Comments
 (0)