From b9b6d09769c1cb45fc60b72f332caacfa1048619 Mon Sep 17 00:00:00 2001 From: opi Date: Wed, 18 Feb 2015 14:35:13 +0100 Subject: [PATCH] [fix] Prevent adding the same cookie again and again. --- helpers.lua | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/helpers.lua b/helpers.lua index a9a0a63..10065ee 100644 --- a/helpers.lua +++ b/helpers.lua @@ -49,7 +49,9 @@ end -- Set a cookie function cook (cookie_str) - table.insert(cookies, cookie_str) + if not is_in_table(cookies, cookie_str) then + table.insert(cookies, cookie_str) + end end