pending and publish
This commit is contained in:
parent
7fdc3d2919
commit
da60104c96
2 changed files with 7 additions and 5 deletions
|
@ -8,7 +8,7 @@
|
|||
File upload is carried out in the background by that function.
|
||||
*/
|
||||
|
||||
import { SITE_NAME, ENABLE_NO_SOURCE_CLAIMS } from 'config';
|
||||
import { SITE_NAME, ENABLE_NO_SOURCE_CLAIMS, SIMPLE_SITE } from 'config';
|
||||
import React, { useEffect } from 'react';
|
||||
import { buildURI, isURIValid, isNameValid, THUMBNAIL_STATUSES } from 'lbry-redux';
|
||||
import Button from 'component/button';
|
||||
|
@ -123,7 +123,7 @@ function PublishForm(props: Props) {
|
|||
: Object.values(PUBLISH_MODES).filter((mode) => mode !== PUBLISH_MODES.LIVESTREAM);
|
||||
|
||||
const MODE_TO_I18N_STR = {
|
||||
[PUBLISH_MODES.FILE]: 'File',
|
||||
[PUBLISH_MODES.FILE]: SIMPLE_SITE ? 'Video' : 'File',
|
||||
[PUBLISH_MODES.POST]: 'Post --[noun, markdown post tab button]--',
|
||||
[PUBLISH_MODES.LIVESTREAM]: 'Livestream --[noun, livestream tab button]--',
|
||||
};
|
||||
|
|
|
@ -58,8 +58,10 @@ export default function LivestreamSetupPage(props: Props) {
|
|||
}
|
||||
|
||||
const [livestreamClaims, setLivestreamClaims] = React.useState([]);
|
||||
// $FlowFixMe
|
||||
const pendingLiveStreamClaims = pendingClaims.filter((claim) => !(claim && claim.value && claim.value.source));
|
||||
const pendingLiveStreamClaims =
|
||||
// $FlowFixMe
|
||||
pendingClaims ? pendingClaims.filter((claim) => !(claim && claim.value && claim.value.source)) : [];
|
||||
const pendingLength = pendingLiveStreamClaims.length;
|
||||
const totalLivestreamClaims = pendingLiveStreamClaims.concat(livestreamClaims);
|
||||
|
||||
React.useEffect(() => {
|
||||
|
@ -82,7 +84,7 @@ export default function LivestreamSetupPage(props: Props) {
|
|||
.catch(() => {
|
||||
setLivestreamClaims([]);
|
||||
});
|
||||
}, [activeChannelClaimStr]);
|
||||
}, [activeChannelClaimStr, pendingLength]);
|
||||
|
||||
return (
|
||||
<Page>
|
||||
|
|
Loading…
Reference in a new issue