remove_user.js 749 B

1234567891011121314151617181920
  1. "use strict";
  2. Object.defineProperty(exports, "__esModule", { value: true });
  3. exports.RemoveUserOperation = void 0;
  4. const command_1 = require("./command");
  5. const operation_1 = require("./operation");
  6. /** @internal */
  7. class RemoveUserOperation extends command_1.CommandOperation {
  8. constructor(db, username, options) {
  9. super(db, options);
  10. this.options = options;
  11. this.username = username;
  12. }
  13. async execute(server, session) {
  14. await super.executeCommand(server, session, { dropUser: this.username });
  15. return true;
  16. }
  17. }
  18. exports.RemoveUserOperation = RemoveUserOperation;
  19. (0, operation_1.defineAspects)(RemoveUserOperation, [operation_1.Aspect.WRITE_OPERATION]);
  20. //# sourceMappingURL=remove_user.js.map