sr-npm 1.7.918 → 1.7.919

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sr-npm",
3
- "version": "1.7.918",
3
+ "version": "1.7.919",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -40,9 +40,9 @@ async function getCategoryValueId(customValues) {
40
40
  const multiRefField=await getPositionWithMultiRefField(item._id);
41
41
  const categoryValueId=await getCategoryValueId(multiRefField);
42
42
  const relatedJobs=await getRelatedJobs(categoryValueId,item._id,5);
43
- if(_$w('#relatedJobsRepNoDepartment')) // when there is no department, we filter based on category
43
+ console.log("relatedJobs: ", relatedJobs);
44
+ if(_$w('#relatedJobsRepNoDepartment') && relatedJobs.length>0) // when there is no department, we filter based on category
44
45
  {
45
- const relatedJobs=await getRelatedJobs(categoryValueId,item._id,5);
46
46
  _$w('#relatedJobsRepNoDepartment').onItemReady(($item, itemData) => {
47
47
  $item('#relatedJobTitle').text = itemData.title;
48
48
  $item('#relatedJobLocation').text = itemData.location.fullLocation;