Removes possibility of no channel being passed in & propogates errors

This commit is contained in:
Oleg Silkin 2020-01-03 18:15:16 -05:00 committed by Lex Berezhny
parent c0a6f6fd08
commit b31881f424

View file

@ -4594,14 +4594,11 @@ class Daemon(metaclass=JSONRPCServerType):
comment_id=comment_id comment_id=comment_id
) )
if 'error' in channel: if 'error' in channel:
return raise ValueError(channel['error'])
wallet = self.wallet_manager.get_wallet_or_default(wallet_id) wallet = self.wallet_manager.get_wallet_or_default(wallet_id)
# channel = await self.get_channel_or_none(wallet, None, **channel) # channel = await self.get_channel_or_none(wallet, None, **channel)
channel_claim = await self.get_channel_or_none(wallet, [], **channel) channel_claim = await self.get_channel_or_error(wallet, [], **channel)
if channel_claim is None:
return
edited_comment = { edited_comment = {
'comment_id': comment_id, 'comment_id': comment_id,
'comment': comment, 'comment': comment,