fix: updates!
This commit is contained in:
parent
adbafa4194
commit
b98fffc386
2 changed files with 15 additions and 5 deletions
|
@ -47,7 +47,7 @@ const createPublishParams = (
|
|||
publishParams['thumbnail_url'] = thumbnail;
|
||||
}
|
||||
if (nsfw) {
|
||||
publishParams.tags = 'mature';
|
||||
publishParams.tags = ['mature'];
|
||||
}
|
||||
// add channel details if publishing to a channel
|
||||
if (channelName && channelClaimId) {
|
||||
|
|
|
@ -149,9 +149,19 @@ const claimUpdate = ({ body, files, headers, ip, originalUrl, user, tor }, res)
|
|||
claim_address: primaryClaimAddress,
|
||||
channel_name: channelName,
|
||||
channel_id: channelId,
|
||||
metadata,
|
||||
title,
|
||||
description,
|
||||
author: details.title,
|
||||
languages: ['en'],
|
||||
license: license || '',
|
||||
license_url: licenseUrl || '',
|
||||
tags: [],
|
||||
};
|
||||
|
||||
if (nsfw) {
|
||||
publishParams.tags = ['mature'];
|
||||
}
|
||||
|
||||
if (files.file) {
|
||||
if (thumbnailUpdate) {
|
||||
// publish new thumbnail
|
||||
|
@ -185,14 +195,14 @@ const claimUpdate = ({ body, files, headers, ip, originalUrl, user, tor }, res)
|
|||
|
||||
if (channelName) {
|
||||
return chainquery.claim.queries.getShortClaimIdFromLongClaimId(
|
||||
result.certificateId,
|
||||
publishResult.certificateId,
|
||||
channelName
|
||||
);
|
||||
} else {
|
||||
return chainquery.claim.queries
|
||||
.getShortClaimIdFromLongClaimId(result.claimId, name, result)
|
||||
.getShortClaimIdFromLongClaimId(publishResult.claimId, name, publishResult)
|
||||
.catch(() => {
|
||||
return result.claimId.slice(0, 1);
|
||||
return publishResult.claimId.slice(0, 1);
|
||||
});
|
||||
}
|
||||
})
|
||||
|
|
Loading…
Reference in a new issue