Skip to content
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/eventarc/eventarc-utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@

import { PrefixedFirebaseError } from '../utils/error';
import { CloudEvent } from './cloudevent';
import { v4 as uuid } from 'uuid';
import * as crypto from 'crypto';
import * as validator from '../utils/validator';

// List of CloudEvent properties that are handled "by hand" and should be skipped by
Expand Down Expand Up @@ -50,7 +50,7 @@ export function toCloudEventProtoFormat(ce: CloudEvent): any {
}
const out: Record<string, any> = {
'@type': 'type.googleapis.com/io.cloudevents.v1.CloudEvent',
'id': ce.id ?? uuid(),
'id': ce.id ?? crypto.randomUUID(),
'type': ce.type,
'specVersion': ce.specversion ?? '1.0',
'source': source
Expand Down
Loading