Closed dtonys closed 11 years ago
In the following example, I think the things_to_save array should be the first argument of the save function.
var things_to_save = []; for(var i = 0; i < 5; i++) { var robj = riak.bucket('users').objects.new('me'+i, { about_me: "I write software." }); robj.addMeta('extra_info', 'data goes up in here'); robj.addToIndex('numbers_i_like', [20, 3, 6]); things_to_save.push(robj); } riak.bucket('users').objects.save(objs, function(errs, objs) { console.log(objs); console.warn(errs); });
The save function should look like this, right?
riak.bucket('users').objects.save(things_to_save, function(errs, objs) { console.log(objs); console.warn(errs); });
Right you are! Thanks for catching that. I'll fix it tonight.
In the following example, I think the things_to_save array should be the first argument of the save function.
The save function should look like this, right?