Skip to content

Commit

Permalink
improve GetVal macro error message #1554
Browse files Browse the repository at this point in the history
  • Loading branch information
RogerHaase committed Dec 30, 2023
1 parent 40522c8 commit 5e82d34
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/moin/macros/GetVal.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,5 +30,5 @@ def macro(self, content, arguments, page_url, alternative):
raise ValueError(_("GetVal: dict not found: ") + item_name)
result = d.get(key, '')
if not result:
return _('GetVal macro is invalid, dict missing key: {keyname}').format(keyname=arguments[0])
raise ValueError(_('GetVal macro is invalid, {item_name} missing key: {key_name}').format(item_name=item_name,key_name=key))
return result

0 comments on commit 5e82d34

Please sign in to comment.