Commit With Frontend and Backend in MERN
This commit is contained in:
30
backend/node_modules/mongodb/lib/operations/search_indexes/create.js
generated
vendored
Normal file
30
backend/node_modules/mongodb/lib/operations/search_indexes/create.js
generated
vendored
Normal file
@@ -0,0 +1,30 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.CreateSearchIndexesOperation = void 0;
|
||||
const operation_1 = require("../operation");
|
||||
/** @internal */
|
||||
class CreateSearchIndexesOperation extends operation_1.AbstractOperation {
|
||||
constructor(collection, descriptions) {
|
||||
super();
|
||||
this.collection = collection;
|
||||
this.descriptions = descriptions;
|
||||
}
|
||||
get commandName() {
|
||||
return 'createSearchIndexes';
|
||||
}
|
||||
async execute(server, session, timeoutContext) {
|
||||
const namespace = this.collection.fullNamespace;
|
||||
const command = {
|
||||
createSearchIndexes: namespace.collection,
|
||||
indexes: this.descriptions
|
||||
};
|
||||
const res = await server.command(namespace, command, {
|
||||
session,
|
||||
timeoutContext
|
||||
});
|
||||
const indexesCreated = res?.indexesCreated ?? [];
|
||||
return indexesCreated.map(({ name }) => name);
|
||||
}
|
||||
}
|
||||
exports.CreateSearchIndexesOperation = CreateSearchIndexesOperation;
|
||||
//# sourceMappingURL=create.js.map
|
||||
1
backend/node_modules/mongodb/lib/operations/search_indexes/create.js.map
generated
vendored
Normal file
1
backend/node_modules/mongodb/lib/operations/search_indexes/create.js.map
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"create.js","sourceRoot":"","sources":["../../../src/operations/search_indexes/create.ts"],"names":[],"mappings":";;;AAKA,4CAAiD;AAgBjD,gBAAgB;AAChB,MAAa,4BAA6B,SAAQ,6BAA2B;IAC3E,YACmB,UAAsB,EACtB,YAAmD;QAEpE,KAAK,EAAE,CAAC;QAHS,eAAU,GAAV,UAAU,CAAY;QACtB,iBAAY,GAAZ,YAAY,CAAuC;IAGtE,CAAC;IAED,IAAa,WAAW;QACtB,OAAO,qBAA8B,CAAC;IACxC,CAAC;IAEQ,KAAK,CAAC,OAAO,CACpB,MAAc,EACd,OAAkC,EAClC,cAA8B;QAE9B,MAAM,SAAS,GAAG,IAAI,CAAC,UAAU,CAAC,aAAa,CAAC;QAChD,MAAM,OAAO,GAAG;YACd,mBAAmB,EAAE,SAAS,CAAC,UAAU;YACzC,OAAO,EAAE,IAAI,CAAC,YAAY;SAC3B,CAAC;QAEF,MAAM,GAAG,GAAG,MAAM,MAAM,CAAC,OAAO,CAAC,SAAS,EAAE,OAAO,EAAE;YACnD,OAAO;YACP,cAAc;SACf,CAAC,CAAC;QAEH,MAAM,cAAc,GAA4B,GAAG,EAAE,cAAc,IAAI,EAAE,CAAC;QAC1E,OAAO,cAAc,CAAC,GAAG,CAAC,CAAC,EAAE,IAAI,EAAE,EAAE,EAAE,CAAC,IAAI,CAAC,CAAC;IAChD,CAAC;CACF;AA/BD,oEA+BC"}
|
||||
36
backend/node_modules/mongodb/lib/operations/search_indexes/drop.js
generated
vendored
Normal file
36
backend/node_modules/mongodb/lib/operations/search_indexes/drop.js
generated
vendored
Normal file
@@ -0,0 +1,36 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.DropSearchIndexOperation = void 0;
|
||||
const error_1 = require("../../error");
|
||||
const operation_1 = require("../operation");
|
||||
/** @internal */
|
||||
class DropSearchIndexOperation extends operation_1.AbstractOperation {
|
||||
constructor(collection, name) {
|
||||
super();
|
||||
this.collection = collection;
|
||||
this.name = name;
|
||||
}
|
||||
get commandName() {
|
||||
return 'dropSearchIndex';
|
||||
}
|
||||
async execute(server, session, timeoutContext) {
|
||||
const namespace = this.collection.fullNamespace;
|
||||
const command = {
|
||||
dropSearchIndex: namespace.collection
|
||||
};
|
||||
if (typeof this.name === 'string') {
|
||||
command.name = this.name;
|
||||
}
|
||||
try {
|
||||
await server.command(namespace, command, { session, timeoutContext });
|
||||
}
|
||||
catch (error) {
|
||||
const isNamespaceNotFoundError = error instanceof error_1.MongoServerError && error.code === error_1.MONGODB_ERROR_CODES.NamespaceNotFound;
|
||||
if (!isNamespaceNotFoundError) {
|
||||
throw error;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
exports.DropSearchIndexOperation = DropSearchIndexOperation;
|
||||
//# sourceMappingURL=drop.js.map
|
||||
1
backend/node_modules/mongodb/lib/operations/search_indexes/drop.js.map
generated
vendored
Normal file
1
backend/node_modules/mongodb/lib/operations/search_indexes/drop.js.map
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"drop.js","sourceRoot":"","sources":["../../../src/operations/search_indexes/drop.ts"],"names":[],"mappings":";;;AAEA,uCAAoE;AAIpE,4CAAiD;AAEjD,gBAAgB;AAChB,MAAa,wBAAyB,SAAQ,6BAAuB;IACnE,YACmB,UAAsB,EACtB,IAAY;QAE7B,KAAK,EAAE,CAAC;QAHS,eAAU,GAAV,UAAU,CAAY;QACtB,SAAI,GAAJ,IAAI,CAAQ;IAG/B,CAAC;IAED,IAAa,WAAW;QACtB,OAAO,iBAA0B,CAAC;IACpC,CAAC;IAEQ,KAAK,CAAC,OAAO,CACpB,MAAc,EACd,OAAkC,EAClC,cAA8B;QAE9B,MAAM,SAAS,GAAG,IAAI,CAAC,UAAU,CAAC,aAAa,CAAC;QAEhD,MAAM,OAAO,GAAa;YACxB,eAAe,EAAE,SAAS,CAAC,UAAU;SACtC,CAAC;QAEF,IAAI,OAAO,IAAI,CAAC,IAAI,KAAK,QAAQ,EAAE,CAAC;YAClC,OAAO,CAAC,IAAI,GAAG,IAAI,CAAC,IAAI,CAAC;QAC3B,CAAC;QAED,IAAI,CAAC;YACH,MAAM,MAAM,CAAC,OAAO,CAAC,SAAS,EAAE,OAAO,EAAE,EAAE,OAAO,EAAE,cAAc,EAAE,CAAC,CAAC;QACxE,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,MAAM,wBAAwB,GAC5B,KAAK,YAAY,wBAAgB,IAAI,KAAK,CAAC,IAAI,KAAK,2BAAmB,CAAC,iBAAiB,CAAC;YAC5F,IAAI,CAAC,wBAAwB,EAAE,CAAC;gBAC9B,MAAM,KAAK,CAAC;YACd,CAAC;QACH,CAAC;IACH,CAAC;CACF;AArCD,4DAqCC"}
|
||||
28
backend/node_modules/mongodb/lib/operations/search_indexes/update.js
generated
vendored
Normal file
28
backend/node_modules/mongodb/lib/operations/search_indexes/update.js
generated
vendored
Normal file
@@ -0,0 +1,28 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.UpdateSearchIndexOperation = void 0;
|
||||
const operation_1 = require("../operation");
|
||||
/** @internal */
|
||||
class UpdateSearchIndexOperation extends operation_1.AbstractOperation {
|
||||
constructor(collection, name, definition) {
|
||||
super();
|
||||
this.collection = collection;
|
||||
this.name = name;
|
||||
this.definition = definition;
|
||||
}
|
||||
get commandName() {
|
||||
return 'updateSearchIndex';
|
||||
}
|
||||
async execute(server, session, timeoutContext) {
|
||||
const namespace = this.collection.fullNamespace;
|
||||
const command = {
|
||||
updateSearchIndex: namespace.collection,
|
||||
name: this.name,
|
||||
definition: this.definition
|
||||
};
|
||||
await server.command(namespace, command, { session, timeoutContext });
|
||||
return;
|
||||
}
|
||||
}
|
||||
exports.UpdateSearchIndexOperation = UpdateSearchIndexOperation;
|
||||
//# sourceMappingURL=update.js.map
|
||||
1
backend/node_modules/mongodb/lib/operations/search_indexes/update.js.map
generated
vendored
Normal file
1
backend/node_modules/mongodb/lib/operations/search_indexes/update.js.map
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"update.js","sourceRoot":"","sources":["../../../src/operations/search_indexes/update.ts"],"names":[],"mappings":";;;AAKA,4CAAiD;AAEjD,gBAAgB;AAChB,MAAa,0BAA2B,SAAQ,6BAAuB;IACrE,YACmB,UAAsB,EACtB,IAAY,EACZ,UAAoB;QAErC,KAAK,EAAE,CAAC;QAJS,eAAU,GAAV,UAAU,CAAY;QACtB,SAAI,GAAJ,IAAI,CAAQ;QACZ,eAAU,GAAV,UAAU,CAAU;IAGvC,CAAC;IAED,IAAa,WAAW;QACtB,OAAO,mBAA4B,CAAC;IACtC,CAAC;IAEQ,KAAK,CAAC,OAAO,CACpB,MAAc,EACd,OAAkC,EAClC,cAA8B;QAE9B,MAAM,SAAS,GAAG,IAAI,CAAC,UAAU,CAAC,aAAa,CAAC;QAChD,MAAM,OAAO,GAAG;YACd,iBAAiB,EAAE,SAAS,CAAC,UAAU;YACvC,IAAI,EAAE,IAAI,CAAC,IAAI;YACf,UAAU,EAAE,IAAI,CAAC,UAAU;SAC5B,CAAC;QAEF,MAAM,MAAM,CAAC,OAAO,CAAC,SAAS,EAAE,OAAO,EAAE,EAAE,OAAO,EAAE,cAAc,EAAE,CAAC,CAAC;QACtE,OAAO;IACT,CAAC;CACF;AA5BD,gEA4BC"}
|
||||
Reference in New Issue
Block a user