aboutsummaryrefslogtreecommitdiffstats
path: root/plugin.go
diff options
context:
space:
mode:
authorLibravatarLibravatar Simon Ser <[email protected]> 2019-12-09 18:35:51 +0100
committerLibravatarLibravatar Simon Ser <[email protected]> 2019-12-09 18:35:51 +0100
commit7702925497a8230f50d2317c9ad41a73de0683ae (patch)
tree617955544543a71baf5c17134a422c0e8fd16bbf /plugin.go
parentefd401bfbf62b2216fe92b4d8be8c07e77b78482 (diff)
downloadalps-7702925497a8230f50d2317c9ad41a73de0683ae.tar.gz
alps-7702925497a8230f50d2317c9ad41a73de0683ae.tar.bz2
alps-7702925497a8230f50d2317c9ad41a73de0683ae.zip
Make SessionManager create the IMAP client
This will allow SessionManager to re-connect when the IMAP server logs the user out.
Diffstat (limited to 'plugin.go')
-rw-r--r--plugin.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/plugin.go b/plugin.go
index 26473b1..9464d60 100644
--- a/plugin.go
+++ b/plugin.go
@@ -38,15 +38,15 @@ func (p *luaPlugin) onRender(l *lua.LState) int {
func (p *luaPlugin) setFilter(l *lua.LState) int {
name := l.CheckString(1)
f := l.CheckFunction(2)
- p.filters[name] = func(args... interface{}) string {
+ p.filters[name] = func(args ...interface{}) string {
luaArgs := make([]lua.LValue, len(args))
for i, v := range args {
luaArgs[i] = luar.New(l, v)
}
err := l.CallByParam(lua.P{
- Fn: f,
- NRet: 1,
+ Fn: f,
+ NRet: 1,
Protect: true,
}, luaArgs...)
if err != nil {