MCPcopy
hub / github.com/ampproject/amphtml / getBinaryTypeNumericalCode

Function getBinaryTypeNumericalCode

ads/google/a4a/utils.js:904–920  ·  view source on GitHub ↗
(type)

Source from the content-addressed store, hash-verified

902 * @return {?string}
903 */
904export function getBinaryTypeNumericalCode(type) {
905 return (
906 {
907 'production': '0',
908 'control': '1',
909 'experimental': '2',
910 'rc': '3',
911 'nightly': '4',
912 'nightly-control': '5',
913 'experimentA': '10',
914 'experimentB': '11',
915 'experimentC': '12',
916 'nomod': '42',
917 'mod': '43',
918 }[type] || null
919 );
920}
921
922/**
923 * Returns whether we are running on the AMP CDN.

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected