Permalink
Browse files

check for nil value in uri

  • Loading branch information...
1 parent 8553880 commit 015f9df9c64d14e6d13fad4208657148239688ae @milomouse committed Jul 18, 2013
Showing with 3 additions and 4 deletions.
  1. +3 −4 luakit/tabmenu.lua
View
@@ -18,7 +18,7 @@ new_mode("tabmenu", {
local rows = {{ " Title", "URI", title = true }}
local escape = lousy.util.escape
for i, view in ipairs(w.tabs.children) do
- local uri = escape(view.uri)
+ local uri = escape(view.uri or "")
local title = escape(view.title or "")
table.insert(rows, { " " .. i .. ": " .. title, " " .. uri, index = i })
end
@@ -82,7 +82,6 @@ add_binds("tabmenu", lousy.util.table.join({
-- Add key binds.
local buf = lousy.bind.buf
add_binds("normal", {
- key({}, "m", function (w)
- w:set_mode("tabmenu")
- end),
+ key({}, "m",
+ function (w) w:set_mode("tabmenu") end),
})

0 comments on commit 015f9df

Please sign in to comment.