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

Feat sort assets in verified tab by uploaded at #3158

Conversation

sultanmyrza
Copy link
Contributor

@sultanmyrza sultanmyrza commented Dec 26, 2023

Fixes #3138

┆Issue is synchronized with this Asana task by Unito

: this.timestamp * MILLISECONDS_PER_SECOND;

try {
const serverTimestampInMilliseconds = Date.parse(this.uploadedAt ?? '');
Copy link
Contributor

Choose a reason for hiding this comment

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

The try-catch clause seems unnecessary here. Date.parse returns NaN for empty string or string that cannot be parsed into timestamp.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@shc261392, you are right I tested with empty string, invalid date string it return NaN. Here is the commit refactor(proof.ts): remove unused try catch block

@sultanmyrza sultanmyrza changed the base branch from v231207-capture-cam-ionic to v240104-capture-cam-ionic-launch January 10, 2024 02:18
@sultanmyrza-numbersprotocol sultanmyrza-numbersprotocol merged commit d09dc29 into v240104-capture-cam-ionic-launch Jan 11, 2024
6 of 7 checks passed
@sultanmyrza sultanmyrza deleted the feat-sort-assets-in-VERIFIED-tab-by-uploaded_at branch March 2, 2024 09:25
@sultanmyrza sultanmyrza restored the feat-sort-assets-in-VERIFIED-tab-by-uploaded_at branch March 2, 2024 09:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants