1b069ba2a1
Needs the metadata sub object removed, everything should be passed at the publish level - no need to set protobuf metadata directly. Thumbnail > thumbnail_url, licenseURL > license_url and possibly a few others. changes fix: 1 of many fix 2 of many fix: 3 of many fix: 4 of many more fixes fix license fix thumb remove tags fix thumb? remove log fix fix txid
26 lines
827 B
JavaScript
26 lines
827 B
JavaScript
const logger = require('winston');
|
|
const { details, publishing } = require('@config/siteConfig');
|
|
|
|
const createThumbnailPublishParams = (thumbnailFilePath, claimName, license, licenseUrl, nsfw) => {
|
|
if (!thumbnailFilePath) {
|
|
return;
|
|
}
|
|
logger.debug(`Creating Thumbnail Publish Parameters`);
|
|
// create the publish params
|
|
return {
|
|
name: `${claimName}-thumb`,
|
|
file_path: thumbnailFilePath,
|
|
bid: publishing.fileClaimBidAmount,
|
|
title: `${claimName} thumbnail`,
|
|
description: `a thumbnail for ${claimName}`,
|
|
author: details.title,
|
|
languages: ['en'],
|
|
license,
|
|
license_url: licenseUrl,
|
|
claim_address: publishing.primaryClaimAddress,
|
|
channel_name: publishing.thumbnailChannel,
|
|
channel_id: publishing.thumbnailChannelId,
|
|
};
|
|
};
|
|
|
|
module.exports = createThumbnailPublishParams;
|