Skip to content

Commit

Permalink
Merge pull request #1226 from MutinyWallet/rm-gateway-fees
Browse files Browse the repository at this point in the history
Don't block on gateway fees
  • Loading branch information
TonyGiorgio authored Jun 18, 2024
2 parents b11e68d + 2bca2cc commit 746588d
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 8 deletions.
6 changes: 0 additions & 6 deletions mutiny-core/src/federation.rs
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,6 @@ pub struct FederationIdentity {
pub federation_name: Option<String>,
pub federation_expiry_timestamp: Option<String>,
pub welcome_message: Option<String>,
pub gateway_fees: Option<GatewayFees>,
// undocumented parameters that fedi uses: https://meta.dev.fedibtc.com/meta.json
pub federation_icon_url: Option<String>,
pub meta_external_url: Option<String>,
Expand Down Expand Up @@ -873,12 +872,10 @@ impl<S: MutinyStorage> FederationClient<S> {
}

pub async fn get_mutiny_federation_identity(&self) -> FederationIdentity {
let gateway_fees = self.gateway_fee().await.ok();
get_federation_identity(
self.uuid.clone(),
self.fedimint_client.clone(),
self.invite_code.clone(),
gateway_fees,
self.logger.clone(),
)
.await
Expand All @@ -895,8 +892,6 @@ pub(crate) async fn get_federation_identity(
uuid: String,
fedimint_client: ClientHandleArc,
invite_code: InviteCode,
gateway_fees: Option<GatewayFees>,

logger: Arc<MutinyLogger>,
) -> FederationIdentity {
let federation_id = fedimint_client.federation_id();
Expand Down Expand Up @@ -950,7 +945,6 @@ pub(crate) async fn get_federation_identity(
fedimint_client.get_meta("welcome_message"),
config.as_ref().and_then(|c| c.welcome_message.clone()),
),
gateway_fees, // Already merged using helper function...
federation_icon_url: merge_values(
fedimint_client.get_meta("federation_icon_url"),
config.as_ref().and_then(|c| c.federation_icon_url.clone()),
Expand Down
2 changes: 0 additions & 2 deletions mutiny-core/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3804,13 +3804,11 @@ pub(crate) async fn create_new_federation<S: MutinyStorage>(
storage.insert_federations(federation_mutex.clone()).await?;

let federation_id = new_federation.fedimint_client.federation_id();
let gateway_fees = new_federation.gateway_fee().await.ok();

let new_federation_identity = get_federation_identity(
next_federation_uuid.clone(),
new_federation.fedimint_client.clone(),
federation_code.clone(),
gateway_fees,
logger.clone(),
)
.await;
Expand Down

0 comments on commit 746588d

Please sign in to comment.