File tree Expand file tree Collapse file tree
backend/graph-proxy/src/graphql Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -216,21 +216,15 @@ impl WorkflowTemplatesQuery {
216216 } else {
217217 CLIENT . get ( url)
218218 } ;
219-
220- let response = request. send ( ) . await ?;
221-
222- if !response. status ( ) . is_success ( ) {
223- return Ok ( Connection :: new ( false , false ) ) ;
224- }
225-
226- let workflow_templates_response =
227- response
219+ let workflow_templates_response = match request. send ( ) . await {
220+ Ok ( resp) => resp
228221 . json :: < APIResult <
229222 argo_workflows_openapi:: IoArgoprojWorkflowV1alpha1ClusterWorkflowTemplateList ,
230223 > > ( )
231224 . await ?
232- . into_result ( ) ?;
233-
225+ . into_result ( ) ,
226+ Err ( _) => return Ok ( Connection :: new ( false , false ) ) ,
227+ } ?;
234228 let workflow_templates = workflow_templates_response
235229 . items
236230 . into_iter ( )
Original file line number Diff line number Diff line change 22 registry : ghcr.io
33 repository : diamondlightsource/workflows-graph-proxy
44 tag : " jamesdoingstuff"
5- digest : " sha256:e37fdb238014fbbb8d8ac8bfb5bc9b402c001ce33ed2b9ab845f883187c8e52e "
5+ digest : " sha256:8eee02f5b52389fcc10fd16b2d8a93750edb65d46d5423ec5266548f65cd3614 "
66 pullPolicy : IfNotPresent
77 pullSecrets : []
88
You can’t perform that action at this time.
0 commit comments