X-Git-Url: https://git.madduck.net/etc/awesome.git/blobdiff_plain/b0209bd820dd5d8c6a2de893444953490f531de0..3c52f47f46762525b6c7d071ca0e494078036bc2:/widgets/imap.lua

diff --git a/widgets/imap.lua b/widgets/imap.lua
index 62b33d7..ea763df 100644
--- a/widgets/imap.lua
+++ b/widgets/imap.lua
@@ -43,9 +43,7 @@ local function worker(args)
 
     if not is_plain
     then
-        local f = io.popen(password)
-        password = f:read("*all"):gsub("\n", "")
-        f:close()
+        password = helpers.read_pipe(password):gsub("\n", "")
     end
 
     imap.widget = wibox.widget.textbox('')