fix: only add expression if truthy
(Don't try to insert empty string) Breaks on some v15 sites Signed-off-by: Akhil Narang <me@akhilnarang.dev>
This commit is contained in:
parent
db3917d720
commit
ec27c44872
1 changed files with 2 additions and 2 deletions
|
|
@ -54,8 +54,8 @@ def execute():
|
|||
for doc in docs:
|
||||
_doc = frappe.get_doc(doctype.name, doc.name)
|
||||
expr = doctype.autoname[7 : doctype.autoname.find("{#")]
|
||||
key = BRACED_PARAMS_WORD_PATTERN.sub(get_param_value_for_word_match(_doc), expr)
|
||||
uniq_exprs.add(key)
|
||||
if key := BRACED_PARAMS_WORD_PATTERN.sub(get_param_value_for_word_match(_doc), expr):
|
||||
uniq_exprs.add(key)
|
||||
|
||||
current = (frappe.qb.from_(Series).select("*").where(Series.name == "")).run(as_dict=True)
|
||||
if current:
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue