Skip to content
This repository has been archived by the owner on Jun 13, 2023. It is now read-only.

Commit

Permalink
fix(google_cloud.js): fix job id extraction (#396)
Browse files Browse the repository at this point in the history
  • Loading branch information
ranrib authored Dec 2, 2020
1 parent debb13e commit 3acacd2
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/events/google_cloud.js
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,9 @@ function bigQueryWrapper(wrappedFunction) {
let jsonMetadata = {};

if (reqOpts.json !== undefined) {
eventName = reqOpts.json.jobReference.jobId;
if (reqOpts.json.jobReference) {
eventName = reqOpts.json.jobReference.jobId;
}
jsonMetadata = reqOpts.json;
} else if (reqOpts.uri !== undefined) {
// eslint-disable-next-line
Expand Down

0 comments on commit 3acacd2

Please sign in to comment.