Du kan inte välja fler än 25 ämnen Ämnen måste starta med en bokstav eller siffra, kan innehålla bindestreck ('-') och vara max 35 tecken långa.

actions.js 871B

1234567891011121314151617181920212223242526272829303132333435363738
  1. /* @flow */
  2. import { SET_LOG_COLLECTOR, SET_LOGGING_CONFIG } from './actionTypes';
  3. /**
  4. * Stores a {@code Logger.LogCollector} instance which will be uploading logs
  5. * to CallStats.
  6. *
  7. * @param {Logger.LogCollector} logCollector - The log collector instance to be
  8. * stored in the Redux state of base/logging feature.
  9. * @returns {{
  10. * type,
  11. * logCollector: Object
  12. * }}
  13. */
  14. export function setLogCollector(logCollector: ?Object) {
  15. return {
  16. type: SET_LOG_COLLECTOR,
  17. logCollector
  18. };
  19. }
  20. /**
  21. * Sets the configuration of the feature base/logging.
  22. *
  23. * @param {Object} config - The configuration to set on the features
  24. * base/logging.
  25. * @returns {{
  26. * type: SET_LOGGING_CONFIG,
  27. * config: Object
  28. * }}
  29. */
  30. export function setLoggingConfig(config: Object) {
  31. return {
  32. type: SET_LOGGING_CONFIG,
  33. config
  34. };
  35. }