dashevo / js-dash-sdk

DEPRECATED Dash client-side library for wallet payment/signing and application development. (Wallet, DAPI, Primitives, BLS, ...)
https://dashevo.github.io/platform/SDK/
MIT License
35 stars 21 forks source link

feat(ClientApps)!: Client.apps signature is an array app definition #156

Closed Alex-Werner closed 3 years ago

Alex-Werner commented 3 years ago

Issue being fixed or feature implemented

In order to handle some bugs where the same contractID were used with multiple string identifier (we set dpns by default, some users might think they want to add it too under another contract alias, which would not populate appDefinition correctly).

What was done?

How Has This Been Tested?

Breaking Changes

Instead of doing previously :

new Dash.Client({
 apps: {
   "dashpay": {
        contractId: '',// Provide the dashpay contract id here
   }
 }
});

Now :

new Dash.Client({
 apps: [{
    contractId: '',// Provide the dashpay contract id here
    alias: 'dashpay'
  }]
});

Checklist:

For repository code-owners and collaborators only

Alex-Werner commented 3 years ago

Fixes: https://github.com/dashevo/js-dash-sdk/issues/150

lgtm-com[bot] commented 3 years ago

This pull request introduces 1 alert when merging 8f590b241d439032858ed36d6a26d3de003f8797 into 4fff21849cbca7074702d85aad69cd16d9f4b30c - view on LGTM.com

new alerts:

lgtm-com[bot] commented 3 years ago

This pull request introduces 1 alert when merging 3ef1a68d2dd06558866c22bf595b23028271a023 into 84761ccaba0255653c3fbd4266cce91803325f39 - view on LGTM.com

new alerts:

shumkov commented 3 years ago

This PR doesn't solve the problem entirely, so we need to sit and design app context logic and then implement it as one thing.