timezone-js-ts
Advanced tools
Comparing version 1.1.13 to 1.1.14
export declare function getCurrentTime(timezone: string): string; | ||
export declare function getAllZones(): string; | ||
export declare function getAllZones(): string[]; |
@@ -38,4 +38,3 @@ "use strict"; | ||
exports.getAllZones = getAllZones; | ||
const path = __importStar(require("path")); | ||
const fs = __importStar(require("fs")); | ||
const zones = __importStar(require("./all_timezone_lists.json")); | ||
function getCurrentTime(timezone) { | ||
@@ -55,5 +54,3 @@ const date = new Date(); | ||
function getAllZones() { | ||
const actualPath = path.resolve(__dirname, '../all_timezone_lists.json'); | ||
const data = fs.readFileSync(actualPath, 'utf-8'); | ||
return data; | ||
return zones; | ||
} |
@@ -25,3 +25,3 @@ const fs = require('fs'); | ||
function getAllZones() { | ||
const actualPath = path.resolve(__dirname, './all_timezone_lists.json'); | ||
const actualPath = path.resolve(__dirname, './src/all_timezone_lists.json'); | ||
const data = fs.readFileSync(actualPath, 'utf-8'); | ||
@@ -28,0 +28,0 @@ return data; |
{ | ||
"name": "timezone-js-ts", | ||
"version": "1.1.13", | ||
"version": "1.1.14", | ||
"description": "", | ||
@@ -5,0 +5,0 @@ "main": "./dist/index.js", |
@@ -1,3 +0,2 @@ | ||
import * as path from "path"; | ||
import * as fs from "fs"; | ||
import * as zones from './all_timezone_lists.json'; | ||
@@ -20,5 +19,3 @@ | ||
export function getAllZones() { | ||
const actualPath = path.resolve(__dirname, '../all_timezone_lists.json'); | ||
const data = fs.readFileSync(actualPath, 'utf-8'); | ||
return data; | ||
return zones; | ||
} |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 1 instance in 1 package
29409
8
1304
2
1