(element, policyId)
| 26 | * @return {!Promise<?Object>} |
| 27 | */ |
| 28 | export function getConsentPolicySharedData(element, policyId) { |
| 29 | return Services.consentPolicyServiceForDocOrNull(element).then( |
| 30 | (consentPolicy) => { |
| 31 | if (!consentPolicy) { |
| 32 | return null; |
| 33 | } |
| 34 | return consentPolicy.getMergedSharedData( |
| 35 | /** @type {string} */ (policyId) |
| 36 | ); |
| 37 | } |
| 38 | ); |
| 39 | } |
| 40 | |
| 41 | /** |
| 42 | * @param {!Element|!ShadowRoot} element |
no test coverage detected