feat(SW-497): Changes to global alert schema
This commit is contained in:
@@ -67,9 +67,9 @@ import {
|
||||
getSiteConfigSuccessCounter,
|
||||
} from "./telemetry"
|
||||
import {
|
||||
getAlertPhoneContactData,
|
||||
getConnections,
|
||||
getFooterConnections,
|
||||
getGlobalAlertPhoneContactData,
|
||||
} from "./utils"
|
||||
|
||||
import type {
|
||||
@@ -667,15 +667,15 @@ export const baseQueryRouter = router({
|
||||
JSON.stringify({ query: { lang } })
|
||||
)
|
||||
|
||||
const { globalAlert } = validatedSiteConfig.data
|
||||
const { sitewideAlert } = validatedSiteConfig.data
|
||||
|
||||
return {
|
||||
...validatedSiteConfig.data,
|
||||
globalAlert: globalAlert
|
||||
sitewideAlert: sitewideAlert
|
||||
? {
|
||||
...globalAlert,
|
||||
...sitewideAlert,
|
||||
phone_contact: contactConfig
|
||||
? getGlobalAlertPhoneContactData(globalAlert, contactConfig)
|
||||
? getAlertPhoneContactData(sitewideAlert, contactConfig)
|
||||
: null,
|
||||
}
|
||||
: null,
|
||||
|
||||
Reference in New Issue
Block a user