@ocap/asset 1.14.6 → 1.14.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/index.js +4 -0
 - package/package.json +9 -9
 
    
        package/lib/index.js
    CHANGED
    
    | 
         @@ -193,6 +193,10 @@ const mintFromFactory = ({ factory, inputs, owner, issuer }) => { 
     | 
|
| 
       193 
193 
     | 
    
         
             
             * @param {object} params.issuer factory issuer wallet and name
         
     | 
| 
       194 
194 
     | 
    
         
             
             */
         
     | 
| 
       195 
195 
     | 
    
         
             
            const preMintFromFactory = ({ factory, inputs, owner, issuer }) => {
         
     | 
| 
      
 196 
     | 
    
         
            +
              if (Object.keys(inputs).some((x) => typeof inputs[x] !== 'string')) {
         
     | 
| 
      
 197 
     | 
    
         
            +
                throw new Error('Failed to mint asset from factory: input values must be strings');
         
     | 
| 
      
 198 
     | 
    
         
            +
              }
         
     | 
| 
      
 199 
     | 
    
         
            +
             
     | 
| 
       196 
200 
     | 
    
         
             
              let asset = null;
         
     | 
| 
       197 
201 
     | 
    
         
             
              const { output, address: factoryAddress, data } = factory;
         
     | 
| 
       198 
202 
     | 
    
         
             
              const { wallet, name } = issuer;
         
     | 
    
        package/package.json
    CHANGED
    
    | 
         @@ -1,7 +1,7 @@ 
     | 
|
| 
       1 
1 
     | 
    
         
             
            {
         
     | 
| 
       2 
2 
     | 
    
         
             
              "name": "@ocap/asset",
         
     | 
| 
       3 
3 
     | 
    
         
             
              "description": "Utility to work with asset and factory on ArcBlock blockchain",
         
     | 
| 
       4 
     | 
    
         
            -
              "version": "1.14. 
     | 
| 
      
 4 
     | 
    
         
            +
              "version": "1.14.7",
         
     | 
| 
       5 
5 
     | 
    
         
             
              "author": {
         
     | 
| 
       6 
6 
     | 
    
         
             
                "name": "wangshijun",
         
     | 
| 
       7 
7 
     | 
    
         
             
                "email": "shijun@arcblock.io",
         
     | 
| 
         @@ -15,13 +15,13 @@ 
     | 
|
| 
       15 
15 
     | 
    
         
             
                "access": "public"
         
     | 
| 
       16 
16 
     | 
    
         
             
              },
         
     | 
| 
       17 
17 
     | 
    
         
             
              "dependencies": {
         
     | 
| 
       18 
     | 
    
         
            -
                "@arcblock/did": "1.14. 
     | 
| 
       19 
     | 
    
         
            -
                "@arcblock/did-util": "1.14. 
     | 
| 
       20 
     | 
    
         
            -
                "@arcblock/vc": "1.14. 
     | 
| 
       21 
     | 
    
         
            -
                "@ocap/contract": "1.14. 
     | 
| 
       22 
     | 
    
         
            -
                "@ocap/mcrypto": "1.14. 
     | 
| 
       23 
     | 
    
         
            -
                "@ocap/util": "1.14. 
     | 
| 
       24 
     | 
    
         
            -
                "@ocap/wallet": "1.14. 
     | 
| 
      
 18 
     | 
    
         
            +
                "@arcblock/did": "1.14.7",
         
     | 
| 
      
 19 
     | 
    
         
            +
                "@arcblock/did-util": "1.14.7",
         
     | 
| 
      
 20 
     | 
    
         
            +
                "@arcblock/vc": "1.14.7",
         
     | 
| 
      
 21 
     | 
    
         
            +
                "@ocap/contract": "1.14.7",
         
     | 
| 
      
 22 
     | 
    
         
            +
                "@ocap/mcrypto": "1.14.7",
         
     | 
| 
      
 23 
     | 
    
         
            +
                "@ocap/util": "1.14.7",
         
     | 
| 
      
 24 
     | 
    
         
            +
                "@ocap/wallet": "1.14.7",
         
     | 
| 
       25 
25 
     | 
    
         
             
                "debug": "^4.3.2",
         
     | 
| 
       26 
26 
     | 
    
         
             
                "empty-value": "^1.0.1",
         
     | 
| 
       27 
27 
     | 
    
         
             
                "flat": "^5.0.2",
         
     | 
| 
         @@ -73,5 +73,5 @@ 
     | 
|
| 
       73 
73 
     | 
    
         
             
                "test": "jest --forceExit --detectOpenHandles",
         
     | 
| 
       74 
74 
     | 
    
         
             
                "coverage": "yarn test -- --coverage"
         
     | 
| 
       75 
75 
     | 
    
         
             
              },
         
     | 
| 
       76 
     | 
    
         
            -
              "gitHead": " 
     | 
| 
      
 76 
     | 
    
         
            +
              "gitHead": "54d1d67b4c1902652083f4143a089da40489cf8d"
         
     | 
| 
       77 
77 
     | 
    
         
             
            }
         
     |