Refactoring

This commit is contained in:
Luis Fernando Molina committed 2021-11-24 15:48:30 +01:00
1 parent 0b855bed3e
commit aa7c6a01b7
4 files changed
+5 -5

No files matched your search

+1 -1
View File
@@ -64,7 +64,7 @@ exports.newDesktopRoot = function newDesktopRoot() {
}
for (let i = 0; i < SA.secrets.array.length; i++) {
let secret = SA.secrets.array[i]
SA.secrets.map.set (secret.signingAccountChildCodeName, secret)
SA.secrets.map.set (secret.nodeCodeName, secret)
}
run()
+1 -1
View File
@@ -62,7 +62,7 @@ exports.newNetworkRoot = function newNetworkRoot() {
}
for (let i = 0; i < SA.secrets.array.length; i++) {
let secret = SA.secrets.array[i]
SA.secrets.map.set(secret.signingAccountChildCodeName, secret)
SA.secrets.map.set(secret.nodeCodeName, secret)
}
NT.app = require('./Network/NetwokNode.js').newNetworkNode()
+1 -1
View File
@@ -31,7 +31,7 @@ exports.newNetworkModulesP2PNetwork = function newNetworkModulesP2PNetwork() {
case 'Network Peer': {
thisObject.p2pNodesToConnect = []
let thisP2PNodeId = SA.secrets.map.get(global.env.P2P_NETWORK_NODE_SIGNING_ACCOUNT).signingAccountChildId
let thisP2PNodeId = SA.secrets.map.get(global.env.P2P_NETWORK_NODE_SIGNING_ACCOUNT).nodeId
for (let i = 0; i < SA.projects.network.globals.memory.arrays.P2P_NETWORK_NODES.length; i++) {
let p2pNetworkNode = SA.projects.network.globals.memory.arrays.P2P_NETWORK_NODES[i]
if (thisP2PNodeId !== p2pNetworkNode.node.id) {
+2 -2
View File
@@ -18,7 +18,7 @@ exports.newNetworkModulesUserProfiles = function newNetworkModulesUserProfiles()
}
async function initialize(signingAccountChildCodeName, p2pNetworkIdentity) {
async function initialize(nodeCodeName, p2pNetworkIdentity) {
let pluginFileNames = await SA.projects.communityPlugins.utilities.plugins.getPluginFileNames(
'Governance',
@@ -95,7 +95,7 @@ exports.newNetworkModulesUserProfiles = function newNetworkModulesUserProfiles()
Now, we will extract the information from the User Profile, specifically of our identity at the p2p network.
*/
if (
signingAccount.signingAccountChild.id === SA.secrets.map.get(signingAccountChildCodeName).signingAccountChildId
signingAccount.signingAccountChild.id === SA.secrets.map.get(nodeCodeName).nodeId
) {
p2pNetworkIdentity.node = signingAccount.signingAccountChild
p2pNetworkIdentity.blockchainAccount = blockchainAccount