mirror of https://github.com/bjc/prosody
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
15 lines
361 B
15 lines
361 B
-- Prosody IM
|
|
-- Copyright (C) 2013 Florian Zeitz
|
|
--
|
|
-- This project is MIT/X11 licensed. Please see the
|
|
-- COPYING file in the source package for more information.
|
|
--
|
|
|
|
local http = {};
|
|
|
|
function http.contains_token(field, token)
|
|
field = ","..field:gsub("[ \t]", ""):lower()..",";
|
|
return field:find(","..token:lower()..",", 1, true) ~= nil;
|
|
end
|
|
|
|
return http;
|
|
|