Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[PM-4045] Get error returned when editing an item with a passkey in the CLI #6379

Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 3 additions & 4 deletions libs/common/src/models/export/fido2key.export.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ export class Fido2KeyExport {
view.rpName = req.rpName;
view.userDisplayName = req.userDisplayName;
view.discoverable = req.discoverable === "true";
view.creationDate = req.creationDate;
view.creationDate = new Date(req.creationDate);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • Is there a need to distinguish whether this is a local or UTC time?
  • What happens if req.creationDate is null? (This is the default value in Fido2KeyView)

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There’s no need to distinguish between a local or UTC.

return view;
}

Expand Down Expand Up @@ -65,7 +65,7 @@ export class Fido2KeyExport {
rpName: string;
userDisplayName: string;
discoverable: string;
creationDate: Date = null;
creationDate: Date;

constructor(o?: Fido2KeyView | Fido2KeyDomain) {
if (o == null) {
Expand All @@ -84,7 +84,6 @@ export class Fido2KeyExport {
this.rpName = o.rpName;
this.userDisplayName = o.userDisplayName;
this.discoverable = String(o.discoverable);
this.creationDate = o.creationDate;
} else {
this.credentialId = o.credentialId?.encryptedString;
this.keyType = o.keyType?.encryptedString;
Expand All @@ -97,7 +96,7 @@ export class Fido2KeyExport {
this.rpName = o.rpName?.encryptedString;
this.userDisplayName = o.userDisplayName?.encryptedString;
this.discoverable = o.discoverable?.encryptedString;
this.creationDate = o.creationDate;
}
this.creationDate = o.creationDate;
}
}
Loading