Skip to content

Commit

Permalink
update asset src
Browse files Browse the repository at this point in the history
  • Loading branch information
NickJ202 committed Sep 16, 2024
1 parent 53a3a2c commit 50082e8
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 13 deletions.
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
"author": "",
"license": "ISC",
"scripts": {
"start:development": "NODE_ENV=development webpack serve --port 3000",
"start:staging": "NODE_ENV=staging webpack serve --port 3000",
"start:development": "NODE_ENV=development webpack serve --port 3001",
"start:staging": "NODE_ENV=staging webpack serve --port 3001",
"format": "eslint --fix . && npx prettier --write .",
"test": "npm test",
"test:verbose": "npm test -- --verbose",
Expand Down
13 changes: 5 additions & 8 deletions src/views/Upload/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -408,13 +408,6 @@ export default function Upload() {
if (uploadReducer.data.renderer)
assetTags.push({ name: TAGS.keys.renderWith, value: uploadReducer.data.renderer });

if (collectionId) {
assetTags.push({ name: TAGS.keys.collectionId, value: collectionId });
if (uploadReducer.data.title) {
assetTags.push({ name: TAGS.keys.collectionName, value: cleanProcessField(uploadReducer.data.title) });
}
}

const aos = connect();

let processSrc = null;
Expand All @@ -430,7 +423,7 @@ export default function Upload() {
}

if (processSrc) {
processSrc = processSrc.replace('[Owner]', `['${arProvider.profile.id}']`);
processSrc = processSrc.replaceAll('<CREATOR>', arProvider.profile.id);
processSrc = processSrc.replaceAll(`'<NAME>'`, cleanProcessField(title));
processSrc = processSrc.replaceAll('<TICKER>', 'ATOMIC');
processSrc = processSrc.replaceAll('<DENOMINATION>', '1');
Expand All @@ -439,6 +432,10 @@ export default function Upload() {
if (!uploadReducer.data.transferableTokens) {
processSrc = processSrc.replace('Transferable = true', 'Transferable = false');
}

if (collectionId) {
processSrc = processSrc.replace('<COLLECTION>', collectionId);
}
}

let processId: string;
Expand Down
6 changes: 3 additions & 3 deletions webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ const productionAddresses = {
PROFILE_SRC: '_R2XYWDPUXVvQrQKFaQRvDTDcDwnQNbqlTd_qvCRSpQ',
COLLECTIONS_REGISTRY: 'TFWDmf8a3_nw43GCm_CuYlYoylHAjCcFGbgHfDaGcsg',
COLLECTION_SRC: '2ZDuM2VUCN8WHoAKOOjiH4_7Apq0ZHKnTWdLppxCdGY',
ASSET_SRC: 'wNkAgE6Sg3HGSVHInfL4LXI1mfOpD6ffSeA4oxmFNfI',
ASSET_SRC: '1FgHdEYzFGmpNp2htuwERpFC0Nlr-vYCvaOLptPofnA',
};

const nonProductionAddresses = {
Expand All @@ -30,7 +30,7 @@ const nonProductionAddresses = {
PROFILE_SRC: '9Tpz5_ZT4RRkF-6JUTdaaTMg0ARfkNuuM5zahXyCqZ4',
COLLECTIONS_REGISTRY: 'q0QVp2rPXOuqIj6mbRObaC-HMweexSv1Y_Nm9_t1brc',
COLLECTION_SRC: '2ZDuM2VUCN8WHoAKOOjiH4_7Apq0ZHKnTWdLppxCdGY',
ASSET_SRC: 'wNkAgE6Sg3HGSVHInfL4LXI1mfOpD6ffSeA4oxmFNfI',
ASSET_SRC: '1FgHdEYzFGmpNp2htuwERpFC0Nlr-vYCvaOLptPofnA',
};

const env = process.env.NODE_ENV || 'development';
Expand All @@ -53,7 +53,7 @@ module.exports = {
},
hot: true,
historyApiFallback: true,
port: 3000,
port: 3001,
open: false,
compress: true,
client: {
Expand Down

0 comments on commit 50082e8

Please sign in to comment.