1
0
Fork 0

remove parser internals from macro implementations

This commit is contained in:
Kevin Matz 2018-10-25 16:39:41 -04:00
parent 54340773bc
commit 1c4c4b18a2
2 changed files with 2 additions and 3 deletions

View File

@ -112,5 +112,4 @@ class OscCommentMacroListener(CommentMacroListener):
ctx.parentCtx.device = ctx
def exitNodeType(self, ctx: CommentMacroParser.NodeTypeContext):
if isinstance(ctx.parentCtx, CommentMacroParser.DeviceContext):
ctx.parentCtx.type = ctx
ctx.parentCtx.type = ctx.getText()

View File

@ -47,7 +47,7 @@ class HogDevice():
if device is None:
osc = list(self.servers.values())[0]
else:
if (device.type.getText() != 'h'):
if (device.type != 'h'):
logger.error("ERROR: Only Hog type devices are supported.")
return
else: