comparison psgxs.js @ 20:957550e2d5a1

Correct an error identifier and use an already defined variable.
author Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
date Tue, 19 Oct 2010 18:55:53 +0200
parents 032090a13fe8
children e55b31f12f8c
comparison
equal deleted inserted replaced
19:032090a13fe8 20:957550e2d5a1
733 return makeError(response, errors.owner.create.instant_nodes_not_supported.n); 733 return makeError(response, errors.owner.create.instant_nodes_not_supported.n);
734 nodeID = utils.makeRandomId(); 734 nodeID = utils.makeRandomId();
735 instant = true; 735 instant = true;
736 } 736 }
737 if (storage.existsNode(nodeID)) 737 if (storage.existsNode(nodeID))
738 return makeError(response, errors.nodeid_already_exists.n); 738 return makeError(response, errors.owner.create.nodeid_already_exists.n);
739 739
740 var bare = toBareJID(to); 740 var bare = toBareJID(to);
741 var right = false; 741 var right = false;
742 742
743 // Check for super-owner 743 // Check for super-owner
772 var conf = form; 772 var conf = form;
773 } 773 }
774 774
775 if (!conf) 775 if (!conf)
776 conf = {}; 776 conf = {};
777 conf['pubsub#creator'] = toBareJID(to); 777 conf['pubsub#creator'] = bare;
778 778
779 var r = storage.createNode(nodeID, conf); 779 var r = storage.createNode(nodeID, conf);
780 if (typeof r == 'number') 780 if (typeof r == 'number')
781 return makeError(response, r); 781 return makeError(response, r);
782 782