From 29702799dc34affee8eb0cddb77ad84ae4a659a7 Mon Sep 17 00:00:00 2001 From: Julien Danjou Date: Tue, 2 Dec 2008 15:56:43 +0100 Subject: [PATCH] beautiful: simplify metatable setting Signed-off-by: Julien Danjou --- lib/beautiful.lua.in | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/lib/beautiful.lua.in b/lib/beautiful.lua.in index d1c25cc8..46c478fc 100644 --- a/lib/beautiful.lua.in +++ b/lib/beautiful.lua.in @@ -18,8 +18,6 @@ local capi = image = image } -local module_name = "beautiful" - --- Theme library module("beautiful") @@ -65,9 +63,9 @@ end --- Get the current theme. -- @return The current theme table. function get() - return package.loaded[module_name] + return _M end -setmetatable(package.loaded[module_name], package.loaded[module_name]) +setmetatable(_M, _M) -- vim: filetype=lua:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:encoding=utf-8:textwidth=80