Merge pull request #161 from lbryio/mobile-date-fix
fix makeSelectDateForUri error on mobile
This commit is contained in:
commit
4bba22d397
2 changed files with 2 additions and 2 deletions
2
dist/bundle.es.js
vendored
2
dist/bundle.es.js
vendored
|
@ -1337,7 +1337,7 @@ const makeSelectMetadataItemForUri = (uri, key) => reselect.createSelector(makeS
|
||||||
const makeSelectTitleForUri = uri => reselect.createSelector(makeSelectMetadataForUri(uri), metadata => metadata && metadata.title);
|
const makeSelectTitleForUri = uri => reselect.createSelector(makeSelectMetadataForUri(uri), metadata => metadata && metadata.title);
|
||||||
|
|
||||||
const makeSelectDateForUri = uri => reselect.createSelector(makeSelectClaimForUri(uri), claim => {
|
const makeSelectDateForUri = uri => reselect.createSelector(makeSelectClaimForUri(uri), claim => {
|
||||||
const timestamp = claim && claim.value && (claim.value.release_time ? claim.value.release_time * 1000 : claim.meta.creation_timestamp * 1000);
|
const timestamp = claim && claim.value && (claim.value.release_time ? claim.value.release_time * 1000 : claim.meta.creation_timestamp ? claim.meta.creation_timestamp * 1000 : null);
|
||||||
if (!timestamp) {
|
if (!timestamp) {
|
||||||
return undefined;
|
return undefined;
|
||||||
}
|
}
|
||||||
|
|
|
@ -195,7 +195,7 @@ export const makeSelectDateForUri = (uri: string) =>
|
||||||
claim.value &&
|
claim.value &&
|
||||||
(claim.value.release_time
|
(claim.value.release_time
|
||||||
? claim.value.release_time * 1000
|
? claim.value.release_time * 1000
|
||||||
: claim.meta.creation_timestamp * 1000);
|
: (claim.meta.creation_timestamp ? claim.meta.creation_timestamp * 1000 : null));
|
||||||
if (!timestamp) {
|
if (!timestamp) {
|
||||||
return undefined;
|
return undefined;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue