lib/amity-mongodb.js
function(collection, callback){
  	// Prep the collection name.
  	var colName = collection.name.split('.');
  	var dbName = colName.shift();
  	colName = colName.join('.');

  	var database = amityMongo.db.db(dbName);

  	var options = {
  		name:dbName + '/' + colName,
  		service:feathersMongo({collection:database.collection(collection.name)})
  	};
  	amityMongo.amity_collections.push(options);
  	callback();
	}
function(collection, callback){
  	// Prep the collection name.
  	var colName = collection.name.split('.');
  	var dbName = colName.shift();
  	colName = colName.join('.');

  	var database = amityMongo.db.db(dbName);

  	var options = {
  		name:dbName + '/' + colName,
  		service:feathersMongo({collection:database.collection(collection.name)})
  	};
  	amityMongo.amity_collections.push(options);
  	callback();
	}
function ( collection , callback ) { // Prep the collection name. var colName = collection . name . split ( '.' ) ; var dbName = colName . shift ( ) ; colName = colName . join ( '.' ) ; var database = amityMongo . db . db ( dbName ) ; var options = { name : dbName + '/' + colName , service : feathersMongo ( { collection : database . collection ( collection . name ) } ) } ; amityMongo . amity_collections . push ( options ) ; callback ( ) ; }
Prepares a service to manage documents in the provided collection. This service will be set up by the Amity server.
Prepares a service to manage documents in the provided collection . This service will be set up by the Amity server .