Software /
code /
prosody-modules
Comparison
mod_firewall/mod_firewall.lua @ 2416:ade918cd9ca7
mod_firewall: Only call rostermanager if username is available (fixes #796)
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Tue, 13 Dec 2016 22:08:02 +0100 |
parent | 2415:07d7036040ee |
child | 2418:ef95853cf900 |
comparison
equal
deleted
inserted
replaced
2415:07d7036040ee | 2416:ade918cd9ca7 |
---|---|
139 }; | 139 }; |
140 rostermanager = { | 140 rostermanager = { |
141 global_code = [[local rostermanager = require "core.rostermanager";]]; | 141 global_code = [[local rostermanager = require "core.rostermanager";]]; |
142 }; | 142 }; |
143 roster_entry = { | 143 roster_entry = { |
144 local_code = [[local roster_entry = (rostermanager.load_roster(to_node, to_host) or {})[bare_from];]]; | 144 local_code = [[local roster_entry = (to_node and rostermanager.load_roster(to_node, to_host) or {})[bare_from];]]; |
145 depends = { "rostermanager", "split_to", "bare_from" }; | 145 depends = { "rostermanager", "split_to", "bare_from" }; |
146 }; | 146 }; |
147 }; | 147 }; |
148 | 148 |
149 local function include_dep(dependency, code) | 149 local function include_dep(dependency, code) |