Changeset

6251:41a5e5205fd9

plugins/muc/occupant: Check for type == nil rather than type ~= unavailable
author daurnimator <quae@daurnimator.com>
date Mon, 19 May 2014 13:47:28 -0400
parents 6250:454ef19e7925
children 6252:10b27981ea3f
files plugins/muc/occupant.lib.lua
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/plugins/muc/occupant.lib.lua	Mon May 19 13:40:54 2014 -0400
+++ b/plugins/muc/occupant.lib.lua	Mon May 19 13:47:28 2014 -0400
@@ -53,7 +53,7 @@
 -- finds another session to be the primary (there might not be one)
 function occupant_mt:choose_new_primary()
 	for jid, pr in self:each_session() do
-		if pr.attr.type ~= "unavailable" then
+		if pr.attr.type == nil then
 			return jid;
 		end
 	end