Skip to content

Commit

Permalink
forgot to get the alias from the input and then use value for the pur…
Browse files Browse the repository at this point in the history
…pose
  • Loading branch information
jrmccannon committed Jul 1, 2024
1 parent 31c7155 commit b3ebeca
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
7 changes: 5 additions & 2 deletions src/AdminConsole/Pages/App/Playground/Client.cshtml
Original file line number Diff line number Diff line change
Expand Up @@ -179,8 +179,12 @@
autoFill(10);
const loginSubmit = async (e) => {
const alias = e.target.alias.value;
if (isStepUp.value) {
const {token, error} = await p.stepup({ signinMethod: { alias: alias }, purpose: selectedPurpose });
const {token, error} = await p.stepup({
signinMethod: { alias: alias },
purpose: selectedPurpose.value
});
if (token) {
await signin(token);
Expand All @@ -190,7 +194,6 @@
}
}
} else {
const alias = e.target.alias.value;
const {token, error} = await p.signinWithAlias(alias);
if (token) {
await signin(token);
Expand Down
2 changes: 1 addition & 1 deletion src/Service/Models/SignInBeginDTO.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ namespace Passwordless.Service.Models;

public class SignInBeginDTO : RequestBase
{
public string Alias { get; set; }
public string Alias { get; init; }
public string UserId { get; init; }
[JsonConverter(typeof(SignInPurposeConverter))]
public SignInPurpose Purpose { get; set; } = SignInPurpose.SignIn;
Expand Down

0 comments on commit b3ebeca

Please sign in to comment.