Skip to content

Commit

Permalink
chg: tidy up is_label_dynamic to return condition directly (#675)
Browse files Browse the repository at this point in the history
  • Loading branch information
lindsay-stevens authored Dec 5, 2023
1 parent ee6bd2d commit 61a4a7d
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions pyxform/survey.py
Original file line number Diff line number Diff line change
Expand Up @@ -172,14 +172,11 @@ def _get_steps_and_target_xpath(context_parent, xpath_parent, include_parent=Fal

@lru_cache(maxsize=65536) # 2^16
def is_label_dynamic(label: str) -> bool:
if (
return (
label is not None
and isinstance(label, str)
and re.search(BRACKETED_TAG_REGEX, label) is not None
):
return True
else:
return False
)


def recursive_dict():
Expand Down

0 comments on commit 61a4a7d

Please sign in to comment.