summaryrefslogtreecommitdiff
path: root/lib/html.fnl
blob: 9cf7b3a793162f368d7201174bddc72390dd7d2f (plain)
1
2
3
4
5
6
7
8
9
10
(fn unescape [s]
  (assert (= (type s) :string) "s must be string")
  (pick-values 1
   (-> s
    (string.gsub "&lt;" "<")
    (string.gsub "&gt;" ">")
    (string.gsub "&quot;" "\"")
    (string.gsub "&amp;" "&"))))

{ : unescape }