Skip to content
This repository has been archived by the owner on Apr 2, 2024. It is now read-only.

fix: check if paymail already exist before creating new one #296

Conversation

pawellewandowski98
Copy link
Contributor

Related links:

GitHub Issue: #295

Description:

  • Checking if paymail exists before creating new one

@mergify
Copy link
Contributor

mergify bot commented Apr 25, 2023

Welcome to our open-source project @pawellewandowski98! 💘

@mrz1836 mrz1836 added hot-fix Urgent or important fix/patch bug-P3 Lowest rated bug, affects nearly none or low-impact labels Apr 25, 2023
Copy link
Member

@mrz1836 mrz1836 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@pawellewandowski98 please see the 1 change required. TY!

@@ -101,6 +102,12 @@ func (c *Client) NewPaymailAddress(ctx context.Context, xPubKey, address, public
return nil, err
}

// Check if the paymail address already exists
paymail, _ := getPaymailAddress(ctx, address, opts...)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@pawellewandowski98 please check the error (just in case!)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done, thanks!

Copy link
Member

@mrz1836 mrz1836 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@mrz1836
Copy link
Member

mrz1836 commented Apr 25, 2023

Closes #295

@mrz1836 mrz1836 merged commit d022bda into BuxOrg:master Apr 25, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug-P3 Lowest rated bug, affects nearly none or low-impact hot-fix Urgent or important fix/patch
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants