Skip to content

Commit

Permalink
Merge pull request #108 from hCaptcha/version-1
Browse files Browse the repository at this point in the history
Update to version 1.0.0
  • Loading branch information
e271828- authored Dec 28, 2021
2 parents 1ad576e + 2ea95a0 commit 6bb18bb
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@hcaptcha/react-hcaptcha",
"version": "0.3.10",
"version": "1.0.0",
"types": "types/index.d.ts",
"main": "dist/index.js",
"files": [
Expand Down
2 changes: 1 addition & 1 deletion src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ const mountCaptchaScript = (params={}) => {
});
};

const domain = params.apihost || "https://hcaptcha.com";
const domain = params.apihost || "https://js.hcaptcha.com";
delete params.apihost;

const script = document.createElement("script");
Expand Down
2 changes: 1 addition & 1 deletion tests/hcaptcha.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,7 @@ describe("hCaptcha", () => {
/>);

const script = document.querySelector("head > script");
expect(script.src).toEqual("https://hcaptcha.com/1/api.js?render=explicit&onload=hcaptchaOnLoad");
expect(script.src).toEqual("https://js.hcaptcha.com/1/api.js?render=explicit&onload=hcaptchaOnLoad");
});

it("apihost should change script src, but not be added as query", () => {
Expand Down

0 comments on commit 6bb18bb

Please sign in to comment.