# HG changeset patch # User Kim Alvefur # Date 1443780744 -7200 # Node ID 7f7920f2aebf8040375c3f88ed6ad4383ed40ed6 # Parent da38775bda82c940ee11cf9048533a8b7eb4b19d Backout 7e820979fd9b (broke tests) diff -r da38775bda82 -r 7f7920f2aebf util/jid.lua --- a/util/jid.lua Sun Sep 27 00:36:34 2015 +0200 +++ b/util/jid.lua Fri Oct 02 12:12:24 2015 +0200 @@ -36,7 +36,11 @@ end local function bare(jid) - return jid and match(jid, "^[^/]+"); + local node, host = _split(jid); + if node and host then + return node.."@"..host; + end + return host; end local function prepped_split(jid)