Skip to content

Commit f2efdbe

Browse files
committed
refactor: 변수명을 좀 더 명확하게 수정
1 parent b89a8a1 commit f2efdbe

File tree

1 file changed

+11
-11
lines changed

1 file changed

+11
-11
lines changed

package/pyconkr-shop/apis/index.ts

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -5,23 +5,23 @@ import ShopAPISchema from "@pyconkr-shop/schemas";
55
export const redirectToProvider = async (
66
socialSignInInfo: ShopAPISchema.SocialSignInRequest
77
) => {
8-
const f = document.createElement("form");
9-
f.method = "POST";
10-
f.action = `${process.env.REACT_APP_PYCONKR_API}/authn/social/browser/v1/auth/provider/redirect`;
8+
const form = document.createElement("form");
9+
form.method = "POST";
10+
form.action = `${process.env.REACT_APP_PYCONKR_API}/authn/social/browser/v1/auth/provider/redirect`;
1111

1212
Object.entries({
1313
...socialSignInInfo,
1414
csrfmiddlewaretoken: shopAPIClient.getCSRFToken() ?? "",
1515
}).forEach(([key, value]) => {
16-
const d = document.createElement("input");
17-
d.type = "hidden";
18-
d.name = key;
19-
d.value = value;
20-
f.appendChild(d);
16+
const inputElement = document.createElement("input");
17+
inputElement.type = "hidden";
18+
inputElement.name = key;
19+
inputElement.value = value;
20+
form.appendChild(inputElement);
2121
});
22-
document.body.appendChild(f);
23-
f.submit();
24-
document.body.removeChild(f);
22+
document.body.appendChild(form);
23+
form.submit();
24+
document.body.removeChild(form);
2525
};
2626

2727
namespace ShopAPIRoute {

0 commit comments

Comments
 (0)