Skip to content

Commit

Permalink
Merge pull request #27 from jigintern/fix/did-login
Browse files Browse the repository at this point in the history
DIDログインの勉強会で指摘があった内容を修正
  • Loading branch information
dicenull committed Aug 22, 2023
2 parents 45d7f92 + a85a2db commit d6d7c0c
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions did-login/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@ DID とは分散型 ID のことで、公開鍵暗号技術の公開鍵のこと
const name = document.getElementById("name").value;
if (name === "") {
document.getElementById("error").innerText = "名前は必須パラメータです";
return;
}
};
</script>
Expand Down Expand Up @@ -125,7 +126,9 @@ document.getElementById("submit").onclick = async () => {
};

// DIDとパスワードの保存処理
document.getElementById("saveBtn").onclick = async () => {
document.getElementById("saveBtn").onclick = async (event) => {
event.preventDefault();

const did = document.getElementById("did").value;
const password = document.getElementById("password").value;
DIDAuth.savePem(did, password);
Expand Down Expand Up @@ -319,7 +322,7 @@ document
// 公開鍵・電子署名をサーバーに渡す
try {
const resp = await fetch(path, {
method,
method: method,
headers: { "Content-Type": "application/json" },
body: JSON.stringify({ did, sign, message }),
});
Expand Down

0 comments on commit d6d7c0c

Please sign in to comment.