Skip to content

Commit

Permalink
Merge pull request #719 from Morg42/develop
Browse files Browse the repository at this point in the history
sdp: add checked_value to resend processing
  • Loading branch information
Morg42 authored Feb 16, 2025
2 parents fdf175b + 78b53d3 commit b6ee96f
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions lib/model/smartdeviceplugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -873,10 +873,11 @@ def captures_value(pattern):
elif isinstance(reply_pattern, list):
return_list = []
for r in reply_pattern:
checked_value = self._commands._commands[command]._check_value(value)
if not captures_value(r):
return_list.append(re.compile(r))
elif value not in return_list:
return_list.append(value)
elif checked_value not in return_list:
return_list.append(checked_value)
reply_pattern = None if None in return_list else return_list
resend_info = {'command': resend_command, 'returnvalue': reply_pattern, 'read_cmd': read_cmd, 'lookup': lookup, 'lookup_ci': lookup_ci}
# if reply pattern does not expect a specific value, use value as expected reply
Expand Down

0 comments on commit b6ee96f

Please sign in to comment.