# HG changeset patch # User Emmanuel Gil Peyrot # Date 1287507234 -7200 # Node ID 032090a13fe80a921a80d3120cf4eaaea55e7d85 # Parent 75625771e41059762684f3d47a06d4d4eda66efe Can’t send subscription-options to non-subscribed people. diff --git a/psgxs.js b/psgxs.js --- a/psgxs.js +++ b/psgxs.js @@ -249,7 +249,7 @@ function onIq(stanza) { return makeError(response, errors.sub.configure.insufficient_privileges.n); var subs = storage.getSubscription(jid, nodeID); - if (subs == {}) + if (!subs.subid) // FIXME: better test for empty object. return makeError(response, errors.sub.configure.no_such_subscriber.n); var s = xmpp.stanza('options', {node: nodeID, jid: jid});