sr-npm 1.7.29 → 1.7.31
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.
- package/backend/collectionConsts.js +1 -0
- package/backend/data.js +2 -1
- package/package.json +1 -1
package/backend/data.js
CHANGED
|
@@ -180,7 +180,7 @@ async function aggregateJobsByFieldToCMS({ field, collection }) {
|
|
|
180
180
|
throw new Error(`Job ${job._id} has no ${field} field`);
|
|
181
181
|
}
|
|
182
182
|
jobsPerField[job[field]] = (jobsPerField[job[field]] || 0) + 1;
|
|
183
|
-
if (field === 'cityText' && !cityLocationAddress[job[field]] && cityLocations[job[field]]) {
|
|
183
|
+
if (field === 'cityText' && !cityLocationAddress[job[field]] && !cityLocations[job[field]]) {
|
|
184
184
|
cityLocationAddress[job[field]] = job.locationAddress;
|
|
185
185
|
cityLocations[job[field]] = job.location;
|
|
186
186
|
}
|
|
@@ -198,6 +198,7 @@ async function aggregateJobsByFieldToCMS({ field, collection }) {
|
|
|
198
198
|
value = normalizeCityName(value);
|
|
199
199
|
|
|
200
200
|
return {
|
|
201
|
+
title: value,
|
|
201
202
|
_id: value.replace(/\s+/g, ''),
|
|
202
203
|
count: amount,
|
|
203
204
|
locationAddress: locAddress,
|