Browse Source
lnchan: set diagnostic_name
previously was only set for tests
regtest_lnd
SomberNight
6 years ago
No known key found for this signature in database
GPG Key ID: B33B5F232C6271E9
1 changed files with
6 additions and
1 deletions
-
electrum/lnchan.py
|
@ -93,7 +93,12 @@ def str_bytes_dict_to_save(x): |
|
|
|
|
|
|
|
|
class Channel(PrintError): |
|
|
class Channel(PrintError): |
|
|
def diagnostic_name(self): |
|
|
def diagnostic_name(self): |
|
|
return str(self.name) |
|
|
if self.name: |
|
|
|
|
|
return str(self.name) |
|
|
|
|
|
try: |
|
|
|
|
|
return f"lnchan_{bh2u(self.channel_id[-4:])}" |
|
|
|
|
|
except: |
|
|
|
|
|
return super().diagnostic_name() |
|
|
|
|
|
|
|
|
def __init__(self, state, name = None): |
|
|
def __init__(self, state, name = None): |
|
|
assert 'local_state' not in state |
|
|
assert 'local_state' not in state |
|
|