(filters = [], variables = {})
| 133 | } |
| 134 | |
| 135 | function buildRuntimePayload(filters = [], variables = {}) { |
| 136 | const normalizedFilters = dedupeFilters(filters); |
| 137 | const normalizedVariables = sortVariableEntries(variables).reduce((acc, [key, value]) => { |
| 138 | acc[key] = value; |
| 139 | return acc; |
| 140 | }, {}); |
| 141 | |
| 142 | return { |
| 143 | filters: normalizedFilters, |
| 144 | variables: normalizedVariables, |
| 145 | hasRuntimeFilters: normalizedFilters.length > 0 || Object.keys(normalizedVariables).length > 0, |
| 146 | }; |
| 147 | } |
| 148 | |
| 149 | function classifyRuntimePayload(filters = [], variables = {}) { |
| 150 | const normalizedPayload = buildRuntimePayload(filters, variables); |
no test coverage detected