diff --git a/app/assets/scripts/fsm/project/services.js b/app/assets/scripts/fsm/project/services.js index bd944e2c..1169f8bc 100644 --- a/app/assets/scripts/fsm/project/services.js +++ b/app/assets/scripts/fsm/project/services.js @@ -307,9 +307,13 @@ export const services = { } if (nextTimeframe) { - nextTimeframe.tilejson = await apiClient.get( - `project/${projectId}/aoi/${context.currentAoi.id}/timeframe/${nextTimeframe.id}/tiles` - ); + try { + nextTimeframe.tilejson = await apiClient.get( + `project/${projectId}/aoi/${context.currentAoi.id}/timeframe/${nextTimeframe.id}/tiles` + ); + } catch (error) { + toasts.error('There was an error fetching the prediction layer.'); + } nextMosaic = mosaicsList.find( (mosaic) => mosaic.id === nextTimeframe.mosaic );