Skip to content

Commit

Permalink
disable download validation when debugging googleapis/google-cloud-no…
Browse files Browse the repository at this point in the history
  • Loading branch information
cdriesler committed Dec 7, 2021
1 parent e592a0f commit 8402200
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions api/src/gql/schema/graphs/resolvers/Query.ts
Original file line number Diff line number Diff line change
Expand Up @@ -57,10 +57,12 @@ export const Query: BaseResolverMap<never, Arguments['Query']> = {
},
}

// const bucket = admin.storage().bucket('np-graphs')
// const graphJsonPath = versionDocument.get('files.graphJson')
// const graphJsonFile = bucket.file(graphJsonPath)
// const [graphJson] = await graphJsonFile.download({ validation: false })
const bucket = admin.storage().bucket('np-graphs')
const validation = process?.env?.DEBUG !== 'true'

const graphJsonPath = versionDocument.get('files.graphJson')
const graphJsonFile = bucket.file(graphJsonPath)
const [graphJson] = await graphJsonFile.download({ validation })

return record
},
Expand Down

0 comments on commit 8402200

Please sign in to comment.