Skip to content

Commit

Permalink
Merge pull request #66 from kinde-oss/dave/fix/org-code
Browse files Browse the repository at this point in the history
fix: strict equals
  • Loading branch information
DaveOrDead authored Sep 28, 2023
2 parents 5066c69 + 79a95e4 commit 4befc3d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/components/LoginLink.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ import {config} from '../config/index';

export function LoginLink({children, postLoginRedirectURL, orgCode, ...props}) {
let params = new URLSearchParams();
if (orgCode !== null) params.append('org_code', orgCode);
if (postLoginRedirectURL !== null)
if (orgCode != null) params.append('org_code', orgCode);
if (postLoginRedirectURL != null)
params.append('post_login_redirect_url', postLoginRedirectURL);
return (
<a
Expand Down
4 changes: 2 additions & 2 deletions src/components/RegisterLink.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ export function RegisterLink({
...props
}) {
let params = new URLSearchParams();
if (orgCode !== null) params.append('org_code', orgCode);
if (postLoginRedirectURL !== null)
if (orgCode != null) params.append('org_code', orgCode);
if (postLoginRedirectURL != null)
params.append('post_login_redirect_url', postLoginRedirectURL);
return (
<a
Expand Down

0 comments on commit 4befc3d

Please sign in to comment.