shuttlepro-shared 1.1.89 → 1.1.90
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -10,7 +10,7 @@ const CACHE_KEY_ALL = "description_templates_all";
|
|
|
10
10
|
const getCachedAllDescriptionTemplates = async () => {
|
|
11
11
|
let descriptionTemplates = await getRedisData(CACHE_KEY_ALL);
|
|
12
12
|
if (!descriptionTemplates) {
|
|
13
|
-
descriptionTemplates = await DescriptionTemplate.find({}).exec();
|
|
13
|
+
descriptionTemplates = await DescriptionTemplate.find({}).lean().exec();
|
|
14
14
|
await setRedisData(CACHE_KEY_ALL, descriptionTemplates);
|
|
15
15
|
}
|
|
16
16
|
return descriptionTemplates;
|
|
@@ -20,7 +20,7 @@ const getCachedAllDescriptionTemplates = async () => {
|
|
|
20
20
|
* Update cached descriptionTemplates for all workspaces.
|
|
21
21
|
*/
|
|
22
22
|
const updateCachedAllDescriptionTemplates = async () => {
|
|
23
|
-
const descriptionTemplates = await DescriptionTemplate.find({}).exec();
|
|
23
|
+
const descriptionTemplates = await DescriptionTemplate.find({}).lean().exec();
|
|
24
24
|
await setRedisData(CACHE_KEY_ALL, descriptionTemplates);
|
|
25
25
|
};
|
|
26
26
|
|
|
@@ -9,7 +9,7 @@ const CACHE_KEY_ALL = "integrations_all";
|
|
|
9
9
|
const getCachedAllIntegrations = async () => {
|
|
10
10
|
let integrations = await getRedisData(CACHE_KEY_ALL);
|
|
11
11
|
if (!integrations) {
|
|
12
|
-
integrations = await Integration.find({}).exec();
|
|
12
|
+
integrations = await Integration.find({}).lean().exec();
|
|
13
13
|
await setRedisData(CACHE_KEY_ALL, integrations);
|
|
14
14
|
}
|
|
15
15
|
return integrations;
|
|
@@ -19,7 +19,7 @@ const getCachedAllIntegrations = async () => {
|
|
|
19
19
|
* Update cached integrations for all workspaces.
|
|
20
20
|
*/
|
|
21
21
|
const updateCachedAllIntegrations = async () => {
|
|
22
|
-
const integrations = await Integration.find({}).exec();
|
|
22
|
+
const integrations = await Integration.find({}).lean().exec();
|
|
23
23
|
await setRedisData(CACHE_KEY_ALL, integrations);
|
|
24
24
|
};
|
|
25
25
|
|