Skip to content

Commit

Permalink
Update __init__.py
Browse files Browse the repository at this point in the history
  • Loading branch information
GordonZhang2024 authored May 1, 2024
1 parent ed826c9 commit 957aa15
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/xss_shield/__init__.py
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
def escape(s: str) -> str:
s = s.replace('<', '&lt')\
.replace('>', '&gt')\
.replace('&', '&amp')\
s = s.replace('<', '&lt;')\
.replace('>', '&gt;')\
.replace('&', '&amp;')\
.replace(' ', '-')\
.replace("'", "&#39;")\
.replace('"', "&#34;")\
.replace(';', '&#59')\
.replace('/', '&#47')\
.replace(';', '&#59;')\
.replace('/', '&#47;')\

return s

0 comments on commit 957aa15

Please sign in to comment.