<commit_before>import Ember from 'ember';
import ValidatableMixin from 'ember-validation/mixins/validatable';
import AttributeMediator from 'ember-validation/mediators/attribute';
import ValidatorMediator from 'ember-validation/mediators/validator';
import Errors from 'ember-validation/core/errors';
import lookup from 'ember-validation/utils/lookup';

const { RSVP, computed, get, keys, assert, Logger, getWithDefault, getProperties, tryInvoke } = Ember;

var findMediators = function(...names) {
    assert("You should provide at least one attribute name", !Ember.isEmpty(names));

    // Iterating over the names (of attributes) and getting mediators.
    const mediators = Ember.A(names).map((name) => {
      let mediator = this.get("mediators").findBy("attribute", name);
      assert("Mediator for attribute named `" + name + "` not found", mediator);
      return mediator;
    });

    return mediators;
};


/**
  @module
  @augments module:ember/Mixin
  @augments module:addon/mixins/validatable
  @public
*/
export default Ember.Mixin.create(ValidatableMixin, {

  /**
    Defines the properties that will be merged from the superclass
    (instead of overridden).
    @type Array
    @default null
    @public
  */
  mergedProperties: ["validationScheme"],

  /**
    A collection that contains all validators of the class instance that
    implements current mixin. The property fills up by the `initValidation`
    method from `validationScheme` (contains instruction to create validators).
    @type {Array}
  */
  mediators: computed(() => Ember.A()),
<commit_msg>mixin Ember.Evented<commit_after>import Ember from 'ember';
import ValidatableMixin from 'ember-validation/mixins/validatable';
import AttributeMediator from 'ember-validation/mediators/attribute';
import ValidatorMediator from 'ember-validation/mediators/validator';
import Errors from 'ember-validation/core/errors';
import lookup from 'ember-validation/utils/lookup';

const { RSVP, computed, get, keys, assert, Logger, getWithDefault, getProperties, tryInvoke } = Ember;

var findMediators = function(...names) {
    assert("You should provide at least one attribute name", !Ember.isEmpty(names));

    // Iterating over the names (of attributes) and getting mediators.
    const mediators = Ember.A(names).map((name) => {
      let mediator = this.get("mediators").findBy("attribute", name);
      assert("Mediator for attribute named `" + name + "` not found", mediator);
      return mediator;
    });

    return mediators;
};


/**
  @module
  @augments module:ember/Mixin
  @augments module:addon/mixins/validatable
  @public
*/
export default Ember.Mixin.create(ValidatableMixin, Ember.Evented, {

  /**
    Defines the properties that will be merged from the superclass
    (instead of overridden).
    @type Array
    @default null
    @public
  */
  mergedProperties: ["validationScheme"],

  /**
    A collection that contains all validators of the class instance that
    implements current mixin. The property fills up by the `initValidation`
    method from `validationScheme` (contains instruction to create validators).
    @type {Array}
  */
  mediators: computed(() => Ember.A()),

{'fraction_non_alphanumeric': 0.11145996860282574, 'fraction_numerical': 0.0, 'mean_word_length': 4.180487804878049, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '783387', 'n_tokens_mistral': 907, 'n_tokens_neox': 872, 'n_words': 278}