diff --git a/src/modules/main/services/setupNamespace.service.tsx b/src/modules/main/services/setupNamespace.service.tsx index 872e9d3..0cf7c3a 100644 --- a/src/modules/main/services/setupNamespace.service.tsx +++ b/src/modules/main/services/setupNamespace.service.tsx @@ -1,4 +1,4 @@ -import {getJson, postJson} from "@pepfar-react-lib/datim-api"; +import {getJson, postJson } from "@pepfar-react-lib/datim-api"; import {getKeyUid, shareKey} from "../../shared/services/shareKey.service"; const config = require('../../../config/config.json'); diff --git a/src/modules/shared/services/content.service.tsx b/src/modules/shared/services/content.service.tsx index 0dbb70d..4c4f233 100644 --- a/src/modules/shared/services/content.service.tsx +++ b/src/modules/shared/services/content.service.tsx @@ -2,7 +2,7 @@ import sanitize from '../../shared/services/sanitize.service'; import getContentUrl, {getWidgetId} from './contentUrl.service'; import {getKeyUid, shareKey} from "./shareKey.service"; import YAML from 'yaml' -import {getJson, postJson, putJson} from "@pepfar-react-lib/datim-api"; +import {getJson, postJson, putJson,postEmpty} from "@pepfar-react-lib/datim-api"; export enum ContentItemType{ string='string', @@ -81,6 +81,7 @@ export function fetchContent():Promise{ export function saveContent(content) { return putJson(getContentUrl(), { body: content }).catch(async () => { await postJson(getContentUrl(), { body: content }); + await postEmpty('/maintenance/cache'); let widgetId = getWidgetId(); let widgetUid = await getKeyUid(widgetId); return shareKey(widgetUid, 'r-------');