Skip to content

Commit fa9de62

Browse files
committed
infra: error when missing api key
1 parent 13dd162 commit fa9de62

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/utils/Analytics.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,10 @@ class Analytics {
2424
throw new Error('Analytics missing event name')
2525
}
2626

27+
if (!this.apiKey) {
28+
throw new Error('Analytics API KEY is missing')
29+
}
30+
2731
const event = {
2832
user_id: this.user,
2933
event_type: eventName,

0 commit comments

Comments
 (0)