Skip to content

Commit

Permalink
Merge branch 'Windows81-patch-1'
Browse files Browse the repository at this point in the history
refers to #79
  • Loading branch information
TheGreatRefrigerator committed Jul 11, 2024
2 parents da9ecaf + 7fdd364 commit 9f4a37d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
3 changes: 2 additions & 1 deletion src/OrsBase.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,8 @@ class OrsBase {
}
if (Constants.propNames.apiKey in args) {
this.defaultArgs[Constants.propNames.apiKey] = args[Constants.propNames.apiKey]
} else {
} else if (!args[Constants.propNames.host]) {
// Do not error if a host is specified; useful for locally-run instances of ORS
console.error(Constants.missingAPIKeyMsg)
throw new Error(Constants.missingAPIKeyMsg)
}
Expand Down
1 change: 0 additions & 1 deletion src/__tests__/OrsBase.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ describe('Test Base class', () => {

it('passes Host correctly', () => {
const base = new OrsBase({
'api_key': 'test',
'host': 'localhost:8080'
})
expect(base.defaultArgs, 'Base instance').to.haveOwnProperty('host')
Expand Down

0 comments on commit 9f4a37d

Please sign in to comment.