buildURI changes - contentName => streamName
This commit is contained in:
parent
18ff574d0e
commit
b4e8cde4e3
3 changed files with 25 additions and 17 deletions
16
dist/bundle.es.js
vendored
16
dist/bundle.es.js
vendored
|
@ -2923,13 +2923,13 @@ const selectIsStillEditing = reselect.createSelector(selectPublishFormValues, pu
|
|||
|
||||
const {
|
||||
isChannel: currentIsChannel,
|
||||
claimName: currentClaimName,
|
||||
contentName: currentContentName
|
||||
channelName: currentClaimName,
|
||||
streamName: currentContentName
|
||||
} = parseURI(uri);
|
||||
const {
|
||||
isChannel: editIsChannel,
|
||||
claimName: editClaimName,
|
||||
contentName: editContentName
|
||||
channelName: editClaimName,
|
||||
streamName: editContentName
|
||||
} = parseURI(editingURI);
|
||||
|
||||
// Depending on the previous/current use of a channel, we need to compare different things
|
||||
|
@ -2968,8 +2968,12 @@ const selectIsResolvingPublishUris = reselect.createSelector(selectState$5, sele
|
|||
});
|
||||
|
||||
const selectTakeOverAmount = reselect.createSelector(selectState$5, selectMyClaimForUri, selectClaimsByUri, ({ name }, myClaimForUri, claimsByUri) => {
|
||||
if (!name) {
|
||||
return null;
|
||||
}
|
||||
|
||||
// We only care about the winning claim for the short uri
|
||||
const shortUri = buildURI({ contentName: name });
|
||||
const shortUri = buildURI({ streamName: name });
|
||||
const claimForShortUri = claimsByUri[shortUri];
|
||||
|
||||
if (!myClaimForUri && claimForShortUri) {
|
||||
|
@ -4349,7 +4353,7 @@ const publishReducer = handleActions({
|
|||
// The editingUri is the full uri with claim id
|
||||
const shortUri = buildURI({
|
||||
channelName: channel,
|
||||
contentName: name
|
||||
streamName: name
|
||||
});
|
||||
|
||||
return _extends$a({}, defaultState$6, publishData, {
|
||||
|
|
|
@ -27,7 +27,7 @@ type PublishState = {
|
|||
bidError: ?string,
|
||||
otherLicenseDescription: string,
|
||||
licenseUrl: string,
|
||||
tags: Array<string>
|
||||
tags: Array<string>,
|
||||
};
|
||||
|
||||
const defaultState: PublishState = {
|
||||
|
@ -94,7 +94,7 @@ export const publishReducer = handleActions(
|
|||
// The editingUri is the full uri with claim id
|
||||
const shortUri = buildURI({
|
||||
channelName: channel,
|
||||
contentName: name,
|
||||
streamName: name,
|
||||
});
|
||||
|
||||
return {
|
||||
|
|
|
@ -35,13 +35,13 @@ export const selectIsStillEditing = createSelector(
|
|||
|
||||
const {
|
||||
isChannel: currentIsChannel,
|
||||
claimName: currentClaimName,
|
||||
contentName: currentContentName,
|
||||
channelName: currentClaimName,
|
||||
streamName: currentContentName,
|
||||
} = parseURI(uri);
|
||||
const {
|
||||
isChannel: editIsChannel,
|
||||
claimName: editClaimName,
|
||||
contentName: editContentName,
|
||||
channelName: editClaimName,
|
||||
streamName: editContentName,
|
||||
} = parseURI(editingURI);
|
||||
|
||||
// Depending on the previous/current use of a channel, we need to compare different things
|
||||
|
@ -68,10 +68,10 @@ export const selectMyClaimForUri = createSelector(
|
|||
return isStillEditing
|
||||
? claimsById[editClaimId]
|
||||
: myClaims.find(claim =>
|
||||
!contentName
|
||||
? claim.name === claimName
|
||||
: claim.name === contentName || claim.name === claimName
|
||||
);
|
||||
!contentName
|
||||
? claim.name === claimName
|
||||
: claim.name === contentName || claim.name === claimName
|
||||
);
|
||||
}
|
||||
);
|
||||
|
||||
|
@ -101,8 +101,12 @@ export const selectTakeOverAmount = createSelector(
|
|||
selectMyClaimForUri,
|
||||
selectClaimsByUri,
|
||||
({ name }, myClaimForUri, claimsByUri) => {
|
||||
if (!name) {
|
||||
return null;
|
||||
}
|
||||
|
||||
// We only care about the winning claim for the short uri
|
||||
const shortUri = buildURI({ contentName: name });
|
||||
const shortUri = buildURI({ streamName: name });
|
||||
const claimForShortUri = claimsByUri[shortUri];
|
||||
|
||||
if (!myClaimForUri && claimForShortUri) {
|
||||
|
|
Loading…
Reference in a new issue