mirror of
https://github.com/Hopiu/django-notifications.git
synced 2026-03-16 21:30:24 +00:00
Fix nonce attribute string compilation
This commit is contained in:
parent
e30247ac36
commit
22fbaf26aa
1 changed files with 1 additions and 1 deletions
|
|
@ -71,7 +71,7 @@ def register_notify_callbacks(badge_class='live_notify_badge', # pylint: disabl
|
|||
)
|
||||
|
||||
# add a nonce value to the script tag if one is provided
|
||||
nonce_str = ' nonce="{nonce}"'.format(nonce=nonce) if nonce is not None else ""
|
||||
nonce_str = ' nonce="{nonce}"'.format(nonce=nonce) if nonce else ""
|
||||
|
||||
script = '<script type="text/javascript"{nonce}>'.format(nonce=nonce_str) + definitions
|
||||
for callback in callbacks.split(','):
|
||||
|
|
|
|||
Loading…
Reference in a new issue