<commit_before>import { getOwner } from '@ember/application';
import { RecordSourceSettings } from '@orbit/records';

export function applyStandardSourceInjections(
  injections: RecordSourceSettings
): void {
  const app = getOwner(injections);
  const orbitConfig = app.lookup('ember-orbit:config');

  if (!orbitConfig.skipSchemaService) {
    injections.schema = app.lookup(`service:${orbitConfig.services.schema}`);
  }
  if (!orbitConfig.skipBucketService) {
    injections.bucket = app.lookup(`service:${orbitConfig.services.bucket}`);
  }
  if (!orbitConfig.skipKeyMapService) {
    injections.keyMap = app.lookup(`service:${orbitConfig.services.keyMap}`);
  }
  if (!orbitConfig.skipNormalizerService) {
    injections.normalizer = app.lookup(
      `service:${orbitConfig.services.normalizer}`
    );
  }
  if (!orbitConfig.skipValidatorService) {
    injections.validatorFor = app.lookup(
      `service:${orbitConfig.services.validator}`
    );
  }
}<commit_msg>Skip all validations by default when skipValidatorService = true<commit_after>import { getOwner } from '@ember/application';
import { RecordSourceSettings } from '@orbit/records';

export function applyStandardSourceInjections(
  injections: RecordSourceSettings
): void {
  const app = getOwner(injections);
  const orbitConfig = app.lookup('ember-orbit:config');

  if (!orbitConfig.skipSchemaService) {
    injections.schema = app.lookup(`service:${orbitConfig.services.schema}`);
  }
  if (!orbitConfig.skipBucketService) {
    injections.bucket = app.lookup(`service:${orbitConfig.services.bucket}`);
  }
  if (!orbitConfig.skipKeyMapService) {
    injections.keyMap = app.lookup(`service:${orbitConfig.services.keyMap}`);
  }
  if (!orbitConfig.skipNormalizerService) {
    injections.normalizer = app.lookup(
      `service:${orbitConfig.services.normalizer}`
    );
  }
  if (orbitConfig.skipValidatorService) {
    injections.autoValidate = false;
  } else {
    injections.validatorFor = app.lookup(
      `service:${orbitConfig.services.validator}`
    );
  }
}
{'fraction_non_alphanumeric': 0.135386119257087, 'fraction_numerical': 0.0, 'mean_word_length': 4.848571428571429, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '402248', 'n_tokens_mistral': 623, 'n_tokens_neox': 610, 'n_words': 94}