mirror of
https://github.com/aljazceru/ark.git
synced 2026-01-17 10:44:21 +01:00
Fix btc wallet restore (covenantless asp) (#332)
* first account = default btcwallet account (account index 0) * Update server/internal/infrastructure/wallet/btc-embedded/wallet.go Co-authored-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com> Signed-off-by: Louis Singer <41042567+louisinger@users.noreply.github.com> * fix restoration * increase arkd timeout * fix connector signature --------- Signed-off-by: Louis Singer <41042567+louisinger@users.noreply.github.com> Co-authored-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com>
This commit is contained in:
@@ -77,6 +77,8 @@ var (
|
||||
}
|
||||
)
|
||||
|
||||
var timeout = time.Minute
|
||||
|
||||
func walletStatusAction(ctx *cli.Context) error {
|
||||
baseURL := ctx.String("url")
|
||||
tlsCertPath := ctx.String("tls-cert-path")
|
||||
@@ -220,7 +222,7 @@ func post[T any](url, body, key, macaroon, tlsCert string) (result T, err error)
|
||||
req.Header.Add("X-Macaroon", macaroon)
|
||||
}
|
||||
client := &http.Client{
|
||||
Timeout: 30 * time.Second,
|
||||
Timeout: timeout,
|
||||
Transport: &http.Transport{
|
||||
TLSClientConfig: tlsConfig,
|
||||
},
|
||||
@@ -267,7 +269,7 @@ func get[T any](url, key, macaroon, tlsCert string) (result T, err error) {
|
||||
}
|
||||
|
||||
client := &http.Client{
|
||||
Timeout: 30 * time.Second,
|
||||
Timeout: timeout,
|
||||
Transport: &http.Transport{
|
||||
TLSClientConfig: tlsConfig,
|
||||
},
|
||||
@@ -331,7 +333,7 @@ func getBalance(url, macaroon, tlsCert string) (*balance, error) {
|
||||
req.Header.Add("X-Macaroon", macaroon)
|
||||
}
|
||||
client := &http.Client{
|
||||
Timeout: 30 * time.Second,
|
||||
Timeout: timeout,
|
||||
Transport: &http.Transport{
|
||||
TLSClientConfig: tlsConfig,
|
||||
},
|
||||
@@ -384,7 +386,7 @@ func getStatus(url, tlsCert string) (*status, error) {
|
||||
req.Header.Add("Content-Type", "application/json")
|
||||
|
||||
client := &http.Client{
|
||||
Timeout: 30 * time.Second,
|
||||
Timeout: timeout,
|
||||
Transport: &http.Transport{
|
||||
TLSClientConfig: tlsConfig,
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user