From 1afe5edb05da58b6d1b58d436fead1ee6c54d6e4 Mon Sep 17 00:00:00 2001 From: Ale32bit Date: Tue, 6 Oct 2015 21:47:10 +0200 Subject: [PATCH] Update buddies.lua --- src/apps/buddies.lua | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/apps/buddies.lua b/src/apps/buddies.lua index c2ec8e7..3bef994 100644 --- a/src/apps/buddies.lua +++ b/src/apps/buddies.lua @@ -47,9 +47,8 @@ local function add() if y == 1 and x == w then return end - elseif e == "char" then - local add = read() end + add = read() term.setCursorBlink(false) --local check = http.post("http://sertex.esy.es/check.php","user="..add).readLine() @@ -79,8 +78,9 @@ local function remove() return elseif y ~= 1 then if users[y-1] then + local user = users[y-1] if sPhone.yesNo("Remove "..users[y-1].."?",nil,false) then - table.remove(users, users[y-1]) + table.remove(users, user) local f = fs.open("/.sPhone/config/buddies", "w") for i = 1, #users do f.write(users[i].."\n")