1
0

lnurl: clean-up

This commit is contained in:
SomberNight
2022-05-30 20:49:08 +02:00
parent 82e33984ad
commit 649cad0122
8 changed files with 204 additions and 159 deletions

View File

@@ -21,6 +21,8 @@
# CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
# SOFTWARE.
import re
from typing import Optional, Tuple
import dns
import threading
from dns.exception import DNSException
@@ -106,7 +108,7 @@ class Contacts(dict, Logger):
t.daemon = True
t.start()
def resolve_openalias(self, url):
def resolve_openalias(self, url: str) -> Optional[Tuple[str, str, bool]]:
# support email-style addresses, per the OA standard
url = url.replace('@', '.')
try: