@@ -10,7 +10,7 @@ import P2tr "P2tr";
1010import Types "Types" ;
1111import Utils "Utils" ;
1212
13- actor class BasicBitcoin (network : Types . Network ) {
13+ persistent actor class BasicBitcoin (network : Types . Network ) {
1414 type GetUtxosResponse = Types . GetUtxosResponse ;
1515 type MillisatoshiPerVByte = Types . MillisatoshiPerVByte ;
1616 type SendRequest = Types . SendRequest ;
@@ -27,14 +27,14 @@ actor class BasicBitcoin(network : Types.Network) {
2727 // / When developing locally this should be `regtest`.
2828 // / When deploying to the IC this should be `testnet`.
2929 // / `mainnet` is currently unsupported.
30- stable let NETWORK : Network = network;
30+ let NETWORK : Network = network;
3131
3232 // / The derivation path to use for ECDSA secp256k1 or Schnorr BIP340/BIP341 key
3333 // / derivation.
34- let DERIVATION_PATH : [[Nat8 ]] = [];
34+ transient let DERIVATION_PATH : [[Nat8 ]] = [];
3535
3636 // The ECDSA key name.
37- let KEY_NAME : Text = switch NETWORK {
37+ transient let KEY_NAME : Text = switch NETWORK {
3838 // For local development, we use a special test key with dfx.
3939 case (#regtest) "dfx_test_key" ;
4040 // On the IC we're using a test ECDSA key.
@@ -43,8 +43,8 @@ actor class BasicBitcoin(network : Types.Network) {
4343
4444 // Threshold signing APIs instantiated with the management canister ID. Can be
4545 // replaced for cheaper testing.
46- var ecdsa_canister_actor : EcdsaCanisterActor = actor ("aaaaa-aa" );
47- var schnorr_canister_actor : SchnorrCanisterActor = actor ("aaaaa-aa" );
46+ transient var ecdsa_canister_actor : EcdsaCanisterActor = actor ("aaaaa-aa" );
47+ transient var schnorr_canister_actor : SchnorrCanisterActor = actor ("aaaaa-aa" );
4848
4949 // / Returns the balance of the given Bitcoin address.
5050 public func get_balance(address : BitcoinAddress ) : async Satoshi {
0 commit comments