### Delete User
Make the call to the Model layer
@param {Object} options
545919
function deleteUser(options) {
            return models.Base.transaction((t) => {
                options.transacting = t;

                return Promise.all([
                    models.Accesstoken.destroyByUser(options),
                    models.Refreshtoken.destroyByUser(options),
                    models.Post.destroyByAuthor(options)
                ]).then(() => {
                    return models.User.destroy(options);
                }).return(null);
            }).catch((err) => {
                return Promise.reject(new common.errors.NoPermissionError({
                    err: err
                }));
            });
        }
504092
def delete(self, **options):
    
    fut = delete_async(self.key(), **options)
    fut.get_result()
990722
def delete_user(self, user_id, **kwargs):
        
        return DeleteUser(settings=self.settings, **kwargs).call(user_id=user_id, **kwargs)
1176716
function(models, options) {
      var removed = [];
      for (var i = 0; i < models.length; i++) {
        var model = this.get(models[i]);
        if (!model) continue;

        var index = this.indexOf(model);
        this.models.splice(index, 1);
        this.length--;

        // Remove references before triggering 'remove' event to prevent an
        // infinite loop. #3693
        delete this._byId[model.cid];
        var id = this.modelId(model.attributes);
        if (id != null) delete this._byId[id];

        if (!options.silent) {
          options.index = index;
          model.trigger('remove', model, this, options);
        }

        removed.push(model);
        this._removeReference(model, options);
      }
      return removed;
    }
448480
def delete(options = {})
      options = options.merge(role_name: @name)
      resp = @client.delete_role(options)
      resp.data
    end
357067
function(model, options) {
            // Define options
            options = _.defaults(options || {}, {
                silent: false,
                render: true
            });

            this.stopListening(model);

            if (this.items[model.id] == null) return this;

            this.items[model.id].remove();
            this.items[model.id] = null;
            delete this.items[model.id];

            if (!options.silent) this.trigger("remove", model);
            if (options.render) this.update();

            return this;
        }
168467
def delete(options = {}, invalidate = true)
      if invalidate
        self.invalidate
      end
      options = @options.merge(options)
      response = self.class.delete(@uri, options)
      if response.success?
        deserialize(response)
      else
        fail HttpError, response.response
      end
    end
709572
function(event, model, collection, options) {
            if ((event == 'add' || event == 'remove') && collection != this) return;
            if (event == 'destroy') {
                this.remove(model, options);
            }
            this.trigger.apply(this, arguments);
        }
478031
def delete(options = {})
      options = options.merge(platform_application_arn: @arn)
      resp = @client.delete_platform_application(options)
      resp.data
    end
1228211
function destroy(publicAPI, model = {}) {
  const previousDestroy = publicAPI.destroy;

  if (!model.subscriptions) {
    model.subscriptions = [];
  }

  publicAPI.destroy = () => {
    if (previousDestroy) {
      previousDestroy();
    }
    while (model.subscriptions && model.subscriptions.length) {
      model.subscriptions.pop().unsubscribe();
    }
    Object.keys(model).forEach((field) => {
      delete model[field];
    });

    // Flag the instance beeing deleted
    model.deleted = true;
  };
}
1085021
def delete(options = {})
      options = options.merge(table_name: @name)
      resp = @client.delete_table(options)
      resp.data
    end
253090
function(resp, options) {
        var request = resp.priv;
        if(options.callback) {
            if(request.status >= 200 && request.status < 300) {
                // success
                if(resp.requestType != "delete") {
                    resp.features = this.parseFeatures(request);
                }
                resp.code = OpenLayers.Protocol.Response.SUCCESS;
            } else {
                // failure
                resp.code = OpenLayers.Protocol.Response.FAILURE;
            }
            options.callback.call(options.scope, resp);
        }
    }
1352286
function(options, callback) {
      if(typeof options === 'function') {
        callback = options;
        options = {};
      }
      if(options.items) {
        options.users = options.users || [];
        for(var i = 0; i < options.items.length ; i++){
          options.users.push(options.items[i]._key);
        }
        delete options.items;
      }
      if(options.title) {
        options.label = options.title;
        delete options.title;
      }
      if (!self.context.player || !options.users || options.users.length === 0 ) {
        callback.apply(self);
      } else {
        UT.Expression._callAPI('dialog.users', [options], function(){
          callback.apply(self);
        });
      }
    }
982472
def delete(options = {})
      options = options.merge(
        role_name: @role_name,
        policy_name: @name
      )
      resp = @client.delete_role_policy(options)
      resp.data
    end
760417
function(model, options) {
            var item, tag;

            // Define options
            options = _.defaults(options || {}, {
                silent: false,
                render: true,
                at: _.size(this.items),
            });

            if (this.items[model.id] != null) {
                this.removeModel(model);
            }

            item = new this.Item({
                "model": model,
                "list": this,
                "collection": this.collection
            }, this);
            this.listenTo(model, "set", function() {
                item.update();
                this.applyFilter(item);
            });
            this.listenTo(model, "id", function(newId, oldId) {
                this.items[newId] = this.items[oldId];
                delete this.items[oldId];
            });

            item.update();
            tag = this.Item.prototype.tagName;
            if (this.Item.prototype.className) tag = tag+"."+this.Item.prototype.className.split(" ")[0];

            if (options.at > 0) {
                this.$("> "+tag).eq(options.at-1).after(item.$el);
            } else {
                this.$el.prepend(item.$el);
            }
            this.items[model.id] = item;

            this.applyFilter(item);

            if (!options.silent) this.trigger("add", model);
            if (options.render) this.update();

            return this;
        }
652075
def delete(options = {})
      options = options.merge(
        policy_arn: @arn,
        version_id: @version_id
      )
      resp = @client.delete_policy_version(options)
      resp.data
    end
593720
def delete(self, option):
        
        if self.config is not None:
            if option in self.config:
                del self.config[option]