Uses rawCollection() for direct db access

Updated tests accordingly to changed access
This commit is contained in:
Peter Theill
2016-02-09 00:36:45 +01:00
parent 7733ab9625
commit 8b3f8751f4
5 changed files with 83 additions and 59 deletions

View File

@@ -64,6 +64,10 @@ ExportAdapter.prototype.collection = function(className) {
throw new Parse.Error(Parse.Error.INVALID_CLASS_NAME,
'invalid className: ' + className);
}
return this.rawCollection(className);
};
ExportAdapter.prototype.rawCollection = function(className) {
return this.connect().then(() => {
return this.db.collection(this.collectionPrefix + className);
});