Skip to content

Commit

Permalink
Merge pull request #1050 from Itheum/stg
Browse files Browse the repository at this point in the history
STG -> MAIN
  • Loading branch information
damienen authored Oct 9, 2023
2 parents 53a35d0 + 2934060 commit 23afaae
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 7 deletions.
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "data-dex",
"version": "1.6.0",
"version": "1.6.1",
"description": "The Itheum Data DEX enables you to trade your data using web3 tech",
"dependencies": {
"@chakra-ui/icons": "2.1.0",
Expand Down
2 changes: 1 addition & 1 deletion src/libs/utils/util.ts
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ export const getApiDataDex = (chainID: string) => {

export const getApiDataMarshal = (chainID: string) => {
const envKey = chainID === "1" ? "REACT_APP_ENV_DATAMARSHAL_MAINNET_API" : "REACT_APP_ENV_DATAMARSHAL_DEVNET_API";
const defaultUrl = chainID === "1" ? "https://api.itheumcloud.com/datamarshalapi/achilles/v1" : "https://api.itheumcloud-stg.com/datamarshalapi/achilles/v1";
const defaultUrl = chainID === "1" ? "https://api.itheumcloud.com/datamarshalapi/router/v1" : "https://api.itheumcloud-stg.com/datamarshalapi/router/v1";

return process.env[envKey] || defaultUrl;
};
Expand Down
9 changes: 6 additions & 3 deletions src/pages/AdvertiseData/MintDataMultiversX.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -680,6 +680,7 @@ export default function MintDataMX({ onRfMount, dataCATAccount, setMenuItem }: {
}

const res = await validateBaseInput();

if (res) {
setErrDataNFTStreamGeneric(null);
dataNFTDataStreamAdvertise();
Expand All @@ -704,15 +705,17 @@ export default function MintDataMX({ onRfMount, dataCATAccount, setMenuItem }: {
const requestOptions = {
method: "POST",
headers: myHeaders,
body: JSON.stringify({ dataNFTStreamUrl }),
body: JSON.stringify({
dataNFTStreamUrl,
dataCreatorERDAddress: mxAddress,
}),
};

try {
const res = await fetch(`${getApiDataMarshal(chainID)}/generate`, requestOptions);
const res = await fetch(`${getApiDataMarshal(chainID)}/generate_V2`, requestOptions);
const data = await res.json();

if (data && data.encryptedMessage && data.messageHash) {
// setSellerData(data.encryptedMessage); // the data URL is the seller data in this case
setSaveProgress((prevSaveProgress) => ({ ...prevSaveProgress, s1: 1 }));

buildUniqueImage({
Expand Down

0 comments on commit 23afaae

Please sign in to comment.