(mainnet: boolean)
| 8 | }) |
| 9 | |
| 10 | export const updateAgent = async (mainnet: boolean) => { |
| 11 | const identity = initIdentity(mainnet) |
| 12 | console.log("Identity:", identity.getPrincipal().toText()) |
| 13 | |
| 14 | try { |
| 15 | await agentManager.updateAgent({ |
| 16 | host: mainnet ? "https://ic0.app" : "http://127.0.0.1:4943", |
| 17 | identity |
| 18 | }) |
| 19 | } catch (error) { |
| 20 | console.error("System Actor initialization failed:", error) |
| 21 | } |
| 22 | } |
no test coverage detected