Skip to content

Commit

Permalink
Merge pull request #963 from mikaoelitiana/962-empty-vars
Browse files Browse the repository at this point in the history
Improve error message when an empty var is set
  • Loading branch information
helloanoop authored Nov 18, 2023
2 parents f8c23ed + 500e385 commit 4abb400
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/bruno-js/src/bru.js
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ class Bru {

setVar(key, value) {
if (!key) {
throw new Error('Key is required');
throw new Error('A variable with an empty name has been created but name is required.');
}

if (envVariableNameRegex.test(key) === false) {
Expand Down

0 comments on commit 4abb400

Please sign in to comment.