comparison storage.js @ 35:6697f394301f

Replace util with fdsq to work around a stupid bug.
author Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
date Wed, 10 Nov 2010 01:30:03 +0100
parents 62cbb1c49bc5
children 023f767662d3
comparison
equal deleted inserted replaced
34:dcf1f09f8cee 35:6697f394301f
22 require('./iso8601'); 22 require('./iso8601');
23 var errors = require('./errors'); 23 var errors = require('./errors');
24 var config = require('./configuration'); 24 var config = require('./configuration');
25 var service_configuration = config.service_configuration; 25 var service_configuration = config.service_configuration;
26 var Configuration = config.Configuration; 26 var Configuration = config.Configuration;
27 var utils = require('./util'); 27 var fdsq = require('./fdsq');
28 var toBareJID = utils.toBareJID; 28 var toBareJID = fdsq.toBareJID;
29 29
30 var nodes = require('./nodes'); 30 var nodes = require('./nodes');
31 var Node = nodes.Node; 31 var Node = nodes.Node;
32 var Item = nodes.Item; 32 var Item = nodes.Item;
33 33
204 var node = storage.getNode(nodeID); 204 var node = storage.getNode(nodeID);
205 if (typeof node == 'number') 205 if (typeof node == 'number')
206 return node; 206 return node;
207 207
208 if (typeof itemID != 'string') 208 if (typeof itemID != 'string')
209 itemID = utils.makeRandomId(); 209 itemID = fdsq.makeRandomId();
210 210
211 i = node.setItem(itemID, content); 211 i = node.setItem(itemID, content);
212 if (content) 212 if (content)
213 i.content = content; 213 i.content = content;
214 214