Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,10 @@ private async Task<Result<string>> CreateProjectInfoOnNostr(string nostrKeyHex,
return;
}

tsc.SetResult(Result.Success(okResponse.EventId!));
if (tsc.Task.IsCompleted)
return;

tsc.TrySetResult(Result.Success(okResponse.EventId!));
});

return await tsc.Task;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ public interface IWalletAppService
Task<Result<IEnumerable<BroadcastedTransaction>>> GetTransactions(WalletId walletId);
Task<Result<Balance>> GetBalance(WalletId walletId);
Task<Result<AccountBalanceInfo>> GetAccountBalanceInfo(WalletId walletId);
Task<Result<AccountBalanceInfo>> GetAccountBalanceInfoWithFullRescan(WalletId walletId);
Task<Result<FeeAndSize>> EstimateFeeAndSize(WalletId walletId, Amount amount, Address address, DomainFeeRate feeRate);
Task<Result<Address>> GetNextReceiveAddress(WalletId id);
Task<Result<WalletId>> CreateWallet(string name, string seedwords, Maybe<string> passphrase, string encryptionKey, BitcoinNetwork network);
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
using System.Linq;
using Angor.Sdk.Common;
using Angor.Sdk.Wallet.Application;
using Angor.Sdk.Wallet.Domain;
Expand Down Expand Up @@ -62,6 +61,11 @@ public Task<Result<AccountBalanceInfo>> GetAccountBalanceInfo(WalletId walletId)
return accountBalanceService.GetAccountBalanceInfoAsync(walletId);
}

public Task<Result<AccountBalanceInfo>> GetAccountBalanceInfoWithFullRescan(WalletId walletId)
{
return accountBalanceService.RefreshAccountBalanceInfoAsync(walletId);
}

public async Task<Result<FeeAndSize>> EstimateFeeAndSize(WalletId walletId, Amount amount, Address address, DomainFeeRate feeRate)
{
try
Expand Down
Loading