Merge pull request #53 from franze6/DID-12
Changed methods for fetch data transactions and for get passPhrase
This commit is contained in:
@@ -70,7 +70,7 @@ class Store {
|
||||
}
|
||||
|
||||
fetchTransactionsInfo() {
|
||||
fetchWrapper.get("account/transactions/71ccaeefe22050abc9b36ce0c1744316c11c49e1", {
|
||||
fetchWrapper.get(`account/transactions/${this.address}`, {
|
||||
networkIdentifier: this.nodeInfo.networkIdentifier,
|
||||
lastBlockID: this.nodeInfo.lastBlockID
|
||||
}).then((res) => this.saveInfoTransactions(res))
|
||||
@@ -81,6 +81,15 @@ class Store {
|
||||
sessionStorage.setItem('passPhrase', this._passPhrase);
|
||||
};
|
||||
|
||||
savePastPassPhrase(phrase) {
|
||||
this._passPhrase=phrase
|
||||
sessionStorage.setItem('passPhrase', this._passPhrase);
|
||||
};
|
||||
|
||||
fetchPassPhrase() {
|
||||
this._passPhrase = sessionStorage.getItem('passPhrase')
|
||||
}
|
||||
|
||||
fetchSharedData() {
|
||||
this._keysArray.forEach((elem) => fetchWrapper.get(`data/shared/${elem}`).then((res) => this.changeSharedData(res)))
|
||||
};
|
||||
@@ -99,11 +108,6 @@ class Store {
|
||||
})
|
||||
}
|
||||
|
||||
savePastPassPhrase(phrase) {
|
||||
this._passPhrase = phrase;
|
||||
sessionStorage.setItem('passPhrase', this._passPhrase);
|
||||
};
|
||||
|
||||
saveDataRegistration(data) {
|
||||
this._accountData = data;
|
||||
};
|
||||
@@ -193,9 +197,7 @@ class Store {
|
||||
}
|
||||
|
||||
get passPhrase() {
|
||||
if(sessionStorage.getItem('passPhrase')) {
|
||||
this._passPhrase = sessionStorage.getItem('passPhrase')
|
||||
}
|
||||
this.fetchPassPhrase()
|
||||
return this._passPhrase
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user