diff options
author | 2011-01-21 00:41:36 -0500 | |
---|---|---|
committer | 2011-01-21 00:41:36 -0500 | |
commit | 78bcda2db6b0b8669a6fbcf63b1143602f544416 (patch) | |
tree | df837e91e357573ca84be0b20155189252337cec /core/init.lua | |
parent | 2247eeb38c71da492cb96711e133b353e7c3129d (diff) | |
download | textadept-78bcda2db6b0b8669a6fbcf63b1143602f544416.tar.gz textadept-78bcda2db6b0b8669a6fbcf63b1143602f544416.zip |
Code cleanup.
Diffstat (limited to 'core/init.lua')
-rw-r--r-- | core/init.lua | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/core/init.lua b/core/init.lua index 3daaf7df..fe235f53 100644 --- a/core/init.lua +++ b/core/init.lua @@ -30,10 +30,8 @@ end -- LuaDoc is in core/._G.luadoc. function _G.user_dofile(filename) - if lfs.attributes(_USERHOME..'/'..filename) then - local ok, err = pcall(dofile, _USERHOME..'/'..filename) - if not ok then gui.print(err) end - return ok - end - return false + if not lfs.attributes(_USERHOME..'/'..filename) then return false end + local ok, err = pcall(dofile, _USERHOME..'/'..filename) + if not ok then gui.print(err) end + return ok end |