diff --git a/dist/ObservableCollection.d.ts b/dist/ObservableCollection.d.ts index 32074acf..1d3f0133 100644 --- a/dist/ObservableCollection.d.ts +++ b/dist/ObservableCollection.d.ts @@ -18,7 +18,7 @@ export declare module MongoObservable { fetch?: string[]; transform?: Function; } - function create(collection: Mongo.Collection): Collection; + function fromExisting(collection: Mongo.Collection): Collection; class Collection { private _collection; constructor(nameOrExisting: string | Mongo.Collection, options?: ConstructorOptions); diff --git a/dist/ObservableCollection.js b/dist/ObservableCollection.js index 1af26079..faf32d62 100644 --- a/dist/ObservableCollection.js +++ b/dist/ObservableCollection.js @@ -4,10 +4,10 @@ var ObservableCursor_1 = require('./ObservableCursor'); var MongoObservable; (function (MongoObservable) { 'use strict'; - function create(collection) { + function fromExisting(collection) { return new MongoObservable.Collection(collection); } - MongoObservable.create = create; + MongoObservable.fromExisting = fromExisting; var Collection = (function () { function Collection(nameOrExisting, options) { if (typeof nameOrExisting === 'string') { diff --git a/src/ObservableCollection.ts b/src/ObservableCollection.ts index de22abba..6991a981 100644 --- a/src/ObservableCollection.ts +++ b/src/ObservableCollection.ts @@ -25,7 +25,7 @@ export module MongoObservable { transform ? : Function; } - export function create(collection: Mongo.Collection) { + export function fromExisting(collection: Mongo.Collection) { return new MongoObservable.Collection(collection); }