@8ms/helpers 2.3.28 → 2.3.29

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.
@@ -54,7 +54,7 @@ var GoogleCloudBigqueryNamespace = class extends BaseNamespace {
54
54
  query = async (props) => {
55
55
  await this.ensureInit();
56
56
  let options = { query: "" };
57
- if ("string" === props) options.query = props;
57
+ if ("string" === typeof props) options.query = props;
58
58
  else if (isObject(props)) {
59
59
  options.query = props.query;
60
60
  if (props?.location) options["location"] = props.location;
@@ -1,10 +1,4 @@
1
1
  //#region src/url/url.d.ts
2
- type EnvironmentUrl = {
3
- localhost: string;
4
- development: string;
5
- staging: string;
6
- production: string;
7
- };
8
2
  /**
9
3
  * Does the URL begin with HTTP or HTTPS?
10
4
  */
@@ -21,9 +15,5 @@ declare const buildParameters: (existing?: object, updated?: object) => string;
21
15
  * Create a new relative URL based on the current path.
22
16
  */
23
17
  declare const buildRelative: (router: any, updated?: object) => string;
24
- /**
25
- * Get the current base url.
26
- */
27
- declare const buildEnvironmentUrl: (path: string, url: EnvironmentUrl) => string;
28
18
  //#endregion
29
- export { EnvironmentUrl, buildEnvironmentUrl, buildParameters, buildRelative, isAbsolute, isRelative };
19
+ export { buildParameters, buildRelative, isAbsolute, isRelative };
@@ -1,5 +1,4 @@
1
1
  import { merge } from "../lodash/index.mjs";
2
- import { isDevelopment, isLocalhost, isProduction, isStaging } from "../environment/index.mjs";
3
2
 
4
3
  //#region src/url/url.ts
5
4
  /**
@@ -36,17 +35,6 @@ const buildParameters = (existing = {}, updated = {}) => {
36
35
  const buildRelative = (router, updated = {}) => {
37
36
  return `${router.pathname}${buildParameters(router.query, updated || {})}`;
38
37
  };
39
- /**
40
- * Get the current base url.
41
- */
42
- const buildEnvironmentUrl = (path, url) => {
43
- let response;
44
- if (isDevelopment() && isLocalhost()) response = url.localhost;
45
- else if (isStaging()) response = url.staging;
46
- else if (isProduction()) response = url.production;
47
- else response = url.development;
48
- return response + path || "";
49
- };
50
38
 
51
39
  //#endregion
52
- export { buildEnvironmentUrl, buildParameters, buildRelative, isAbsolute, isRelative };
40
+ export { buildParameters, buildRelative, isAbsolute, isRelative };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@8ms/helpers",
3
3
  "license": "UNLICENSED",
4
- "version": "2.3.28",
4
+ "version": "2.3.29",
5
5
  "repository": {
6
6
  "type": "git",
7
7
  "url": "git+https://github.com/8millionstories-organisation/8ms-helpers-ts.git"