Software /
code /
prosody
Changeset
3135:f29a297471e3
util.filters: Don't traceback when trying to remove a filter from an uninitialized object
author | Matthew Wild <mwild1@gmail.com> |
---|---|
date | Wed, 02 Jun 2010 12:24:07 +0100 |
parents | 3134:9a29ad6a9b97 |
children | 3136:9630cb97cd3e |
files | util/filters.lua |
diffstat | 1 files changed, 1 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/util/filters.lua Wed Jun 02 12:23:07 2010 +0100 +++ b/util/filters.lua Wed Jun 02 12:24:07 2010 +0100 @@ -46,6 +46,7 @@ end function remove_filter(session, type, callback) + if not session.filters then return; end local filter_list = session.filters[type]; if filter_list and filter_list[callback] then for i=1, #filter_list do