Skip to content

Commit

Permalink
fix: update invalid sdk key error message
Browse files Browse the repository at this point in the history
  • Loading branch information
kaushalkapasi committed Aug 7, 2024
1 parent 4d9791e commit 900a71a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion sdk/js/__tests__/index.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ jest.spyOn(Request, 'getConfigJson').mockImplementation(() => {
const test_key = 'client_test_sdk_key'
const missingKeyError = 'Missing SDK key! Call initialize with a valid SDK key'
const invalidKeyError =
'Invalid SDK key! SDK key must start with "client_" or "dvc_client_"'
'Invalid SDK key provided. Please call initialize with a valid client SDK key'
const missingUserError = 'Missing user! Call initialize with a valid user'
const invalidUserError =
'Must have a user_id, or have "isAnonymous" set on the user'
Expand Down
2 changes: 1 addition & 1 deletion sdk/js/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ export function initializeDevCycle<

if (!sdkKey.startsWith('client') && !sdkKey.startsWith('dvc_client')) {
throw new Error(
'Invalid SDK key! SDK key must start with "client_" or "dvc_client_"',
'Invalid SDK key provided. Please call initialize with a valid client SDK key',
)
}

Expand Down

0 comments on commit 900a71a

Please sign in to comment.