Don't show duplicate warnings.

master
Pacman Ghost 4 years ago
parent 3d48e702ed
commit e96750a695
  1. 2
      asl_articles/utils.py

@ -59,7 +59,7 @@ def make_ok_response( extras=None, updated=None, warnings=None ):
if updated:
resp[ "updated" ] = updated
if warnings:
resp[ "warnings" ] = warnings
resp[ "warnings" ] = list( set( warnings ) ) # nb: remove duplicate messages
return jsonify( resp )
# ---------------------------------------------------------------------

Loading…
Cancel
Save