opportunity-service 0.0.655 → 0.0.656
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.
@@ -27,7 +27,8 @@ function registerNewUser() {
|
|
27
27
|
console.log('The true identificaiton is: ' + id);
|
28
28
|
if (id == '0x0000000000000000000000000000000000000000') {
|
29
29
|
console.log('Registering new user: ' + msgSender);
|
30
|
-
const tx = new Contract(addressMap[opportunityService.getEthNetwork()][Contracts.USER_REGISTRATION], abiMap[Contracts.USER_REGISTRATION])
|
30
|
+
const tx = new Contract(addressMap[opportunityService.getEthNetwork()][Contracts.USER_REGISTRATION], abiMap[Contracts.USER_REGISTRATION])
|
31
|
+
.connect(opportunityService.getSignersInterface())
|
31
32
|
.registerNewUser({
|
32
33
|
from: msgSender
|
33
34
|
});
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"register-new-user.js","sourceRoot":"","sources":["../../../src/api/identity/register-new-user.ts"],"names":[],"mappings":";;;;;;;;;AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,EAAe,MAAM,QAAQ,CAAC;AACvD,OAAO,kBAAkB,MAAM,0BAA0B,CAAC;AAC1D,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAE5C,OAAO,UAAU,MAAM,iCAAiC,CAAA;AACxD,OAAO,MAAM,MAAM,2BAA2B,CAAA;
|
1
|
+
{"version":3,"file":"register-new-user.js","sourceRoot":"","sources":["../../../src/api/identity/register-new-user.ts"],"names":[],"mappings":";;;;;;;;;AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,EAAe,MAAM,QAAQ,CAAC;AACvD,OAAO,kBAAkB,MAAM,0BAA0B,CAAC;AAC1D,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAE5C,OAAO,UAAU,MAAM,iCAAiC,CAAA;AACxD,OAAO,MAAM,MAAM,2BAA2B,CAAA;AAI9C,SAAe,eAAe;;QAC1B,OAAO,IAAI,OAAO,CA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AAa,CAAC,CAAA;oBAC1B,OAAO,CAAC,GAAG,CAAC,OAAO,CAAC,CAAA;oBAEpB,IAAI,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,EAAE;wBAC9B,OAAO,CAAC,GAAG,CAAC,uBAAuB,CAAC,CAAA;wBACpC,OAAO,CAAC,IAAI,CAAC,CAAC;qBACjB;yBAAM;wBACH,OAAO,CAAC,GAAG,CAAC,oBAAoB,CAAC,CAAA;wBACjC,OAAO,CAAC,KAAK,CAAC,CAAA;qBACjB;iBACJ;qBAAM;oBACH,OAAO,CAAC,GAAG,CAAC,yBAAyB,CAAC,CAAA;oBACtC,OAAO,CAAC,KAAK,CAAC,CAAA;iBACjB;aAGJ;YAAC,OAAM,KAAK,EAAE;gBACX,OAAO,CAAC,GAAG,CAAC,KAAK,CAAC,CAAA;gBAClB,MAAM,CAAC,8DAA8D,CAAC,CAAA;aACzE;QACL,CAAC,CAAA,CAAC,CAAA;IACN,CAAC;CAAA;AAED,eAAe,eAAe,CAAC"}
|
package/package.json
CHANGED
@@ -5,6 +5,7 @@ import { Contracts } from '../../constants';
|
|
5
5
|
import addressMap from '../../blockchain/addresses.json'
|
6
6
|
import abiMap from '../../blockchain/abi.json'
|
7
7
|
import { Result } from 'ethers/lib/utils';
|
8
|
+
import { TransactionResponse } from '@ethersproject/providers';
|
8
9
|
|
9
10
|
async function registerNewUser() {
|
10
11
|
return new Promise(async (resolve, reject) => {
|
@@ -20,13 +21,13 @@ async function registerNewUser() {
|
|
20
21
|
console.log('Checking true identificaiton of msgSender: ' + msgSender)
|
21
22
|
const id = await userRegistrationInstance.getTrueIdentification(msgSender)
|
22
23
|
console.log('The true identificaiton is: ' + id)
|
23
|
-
|
24
|
+
|
24
25
|
if (id == '0x0000000000000000000000000000000000000000')
|
25
26
|
{
|
26
27
|
console.log('Registering new user: ' + msgSender)
|
27
|
-
const tx = new Contract(
|
28
|
-
addressMap[opportunityService.getEthNetwork()][Contracts.USER_REGISTRATION],
|
29
|
-
|
28
|
+
const tx : TransactionResponse = new Contract(
|
29
|
+
addressMap[opportunityService.getEthNetwork()][Contracts.USER_REGISTRATION], abiMap[Contracts.USER_REGISTRATION])
|
30
|
+
.connect(opportunityService.getSignersInterface())
|
30
31
|
.registerNewUser({
|
31
32
|
from: msgSender
|
32
33
|
})
|