@open-tender/utils 0.1.97 → 0.1.98

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/.DS_Store CHANGED
Binary file
@@ -257,4 +257,4 @@ export declare const LOCATIONS_MESSAGES: {
257
257
  };
258
258
  };
259
259
  };
260
- export declare const renameLocation: (str: unknown, names: Array<string>) => unknown;
260
+ export declare const renameLocation: (str: string, names: string[]) => string;
@@ -2,7 +2,6 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.renameLocation = exports.LOCATIONS_MESSAGES = exports.makeDisplayedRevenueCenters = exports.makeDeliveryMesssaging = exports.makeWalkinMessaging = exports.makePickupMesssaging = exports.makeDeliveryRevenueCenters = exports.makeWalkinRevenueCenters = exports.makePickupRevenueCenters = exports.checkServiceType = exports.calcMinDistance = exports.sortRevenueCenters = exports.addDistance = exports.inZone = exports.getDistance = exports.makeAddress = exports.GooglePlaceBusinessStatus = void 0;
4
4
  const constants_1 = require("./constants");
5
- const helpers_1 = require("./helpers");
6
5
  var GooglePlaceBusinessStatus;
7
6
  (function (GooglePlaceBusinessStatus) {
8
7
  GooglePlaceBusinessStatus["OPERATIONAL"] = "OPERATIONAL";
@@ -273,8 +272,6 @@ exports.LOCATIONS_MESSAGES = {
273
272
  }
274
273
  };
275
274
  const renameLocation = (str, names) => {
276
- if (!(0, helpers_1.isString)(str))
277
- return str;
278
275
  const [singular, plural] = names;
279
276
  return str
280
277
  .replace('1 locations', '1 location')
@@ -257,4 +257,4 @@ export declare const LOCATIONS_MESSAGES: {
257
257
  };
258
258
  };
259
259
  };
260
- export declare const renameLocation: (str: unknown, names: Array<string>) => unknown;
260
+ export declare const renameLocation: (str: string, names: string[]) => string;
@@ -1,5 +1,4 @@
1
1
  import { MAX_DISTANCE } from './constants';
2
- import { isString } from './helpers';
3
2
  export var GooglePlaceBusinessStatus;
4
3
  (function (GooglePlaceBusinessStatus) {
5
4
  GooglePlaceBusinessStatus["OPERATIONAL"] = "OPERATIONAL";
@@ -256,8 +255,6 @@ export const LOCATIONS_MESSAGES = {
256
255
  }
257
256
  };
258
257
  export const renameLocation = (str, names) => {
259
- if (!isString(str))
260
- return str;
261
258
  const [singular, plural] = names;
262
259
  return str
263
260
  .replace('1 locations', '1 location')
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@open-tender/utils",
3
- "version": "0.1.97",
3
+ "version": "0.1.98",
4
4
  "description": "A library of utils for use with Open Tender applications that utilize our cloud-based Order API.",
5
5
  "main": "./dist/cjs/index.js",
6
6
  "module": "./dist/esm/index.js",