jdev_helpers 1.4.2 → 1.4.4

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/dist/index.js CHANGED
@@ -78,10 +78,10 @@ function createHttpParams(customHttpParams) {
78
78
  }
79
79
  function addHttpParams(hp, customHttpParams) {
80
80
  if (customHttpParams.needToCheckValue) {
81
- if (customHttpParams && (customHttpParams.value !== null || customHttpParams.value !== void 0)) {
82
- return hp.append(customHttpParams.key, customHttpParams.value);
83
- } else {
81
+ if (customHttpParams.value === null || customHttpParams.value === void 0) {
84
82
  return hp;
83
+ } else {
84
+ return hp.append(customHttpParams.key, customHttpParams.value);
85
85
  }
86
86
  } else {
87
87
  return hp.append(customHttpParams.key, customHttpParams.value);
package/dist/index.mjs CHANGED
@@ -45,10 +45,10 @@ function createHttpParams(customHttpParams) {
45
45
  }
46
46
  function addHttpParams(hp, customHttpParams) {
47
47
  if (customHttpParams.needToCheckValue) {
48
- if (customHttpParams && (customHttpParams.value !== null || customHttpParams.value !== void 0)) {
49
- return hp.append(customHttpParams.key, customHttpParams.value);
50
- } else {
48
+ if (customHttpParams.value === null || customHttpParams.value === void 0) {
51
49
  return hp;
50
+ } else {
51
+ return hp.append(customHttpParams.key, customHttpParams.value);
52
52
  }
53
53
  } else {
54
54
  return hp.append(customHttpParams.key, customHttpParams.value);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "jdev_helpers",
3
- "version": "1.4.2",
3
+ "version": "1.4.4",
4
4
  "description": "jdev helpers for js and angular",
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/index.mjs",