You are here

function lingotek_test_lingotek_config_object_document_upload in Lingotek Translation 3.2.x

Same name and namespace in other branches
  1. 8.2 tests/modules/lingotek_test/lingotek_test.module \lingotek_test_lingotek_config_object_document_upload()
  2. 4.0.x tests/modules/lingotek_test/lingotek_test.module \lingotek_test_lingotek_config_object_document_upload()
  3. 3.0.x tests/modules/lingotek_test/lingotek_test.module \lingotek_test_lingotek_config_object_document_upload()
  4. 3.1.x tests/modules/lingotek_test/lingotek_test.module \lingotek_test_lingotek_config_object_document_upload()
  5. 3.3.x tests/modules/lingotek_test/lingotek_test.module \lingotek_test_lingotek_config_object_document_upload()
  6. 3.4.x tests/modules/lingotek_test/lingotek_test.module \lingotek_test_lingotek_config_object_document_upload()
  7. 3.5.x tests/modules/lingotek_test/lingotek_test.module \lingotek_test_lingotek_config_object_document_upload()
  8. 3.6.x tests/modules/lingotek_test/lingotek_test.module \lingotek_test_lingotek_config_object_document_upload()
  9. 3.7.x tests/modules/lingotek_test/lingotek_test.module \lingotek_test_lingotek_config_object_document_upload()
  10. 3.8.x tests/modules/lingotek_test/lingotek_test.module \lingotek_test_lingotek_config_object_document_upload()

Implements hook_lingotek_content_object_translation_upload().

File

tests/modules/lingotek_test/lingotek_test.module, line 100
Provides a fake Lingotek API endpoint and other help for testing purposes.

Code

function lingotek_test_lingotek_config_object_document_upload(array &$data, $config_name) {
  if ($config_name === 'system.rss') {

    // Replace Llamas with Cats.
    $data['system.rss']['channel.description'] = str_replace('Llamas', 'Cats', $data['system.rss']['channel.description']);
  }
}