Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@appolo/utils

Package Overview
Dependencies
Maintainers
1
Versions
58
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@appolo/utils - npm Package Compare versions

Comparing version 8.0.15 to 8.0.16

10

lib/time.js

@@ -36,2 +36,12 @@ "use strict";

}
static milisecHuman(ms) {
let str = '';
let date = new Date(ms), days = date.getUTCDate() - 1, hours = date.getUTCHours(), minutes = date.getUTCMinutes(), seconds = date.getUTCSeconds(), milli = date.getUTCMilliseconds();
days && (str += `${days} days, `);
(hours || str) && (str += `${hours} hours, `);
(minutes || str) && (str += `${minutes} minutes, `);
(seconds || str) && (str += `${seconds} seconds, `);
str += `${milli} milli`;
return str;
}
static durationIntToString(durationSeconds) {

@@ -38,0 +48,0 @@ return new Date(durationSeconds * 1000).toISOString().substr(11, 8);

20

lib/time.ts

@@ -49,2 +49,20 @@ import {Numbers} from "../index";

public static milisecHuman(ms: number): string {
let str = '';
let date = new Date(ms),
days = date.getUTCDate() - 1,
hours = date.getUTCHours(),
minutes = date.getUTCMinutes(),
seconds = date.getUTCSeconds(),
milli = date.getUTCMilliseconds();
days && (str += `${days} days, `);
(hours || str) && (str += `${hours} hours, `);
(minutes || str) && (str += `${minutes} minutes, `);
(seconds || str) && (str += `${seconds} seconds, `);
str += `${milli} milli`;
return str;
}
public static durationIntToString(durationSeconds: number): string {

@@ -75,3 +93,3 @@ return new Date(durationSeconds * 1000).toISOString().substr(11, 8);

delay +=(params.min || 0);
delay += (params.min || 0);

@@ -78,0 +96,0 @@ if (params.max) {

2

package.json

@@ -20,3 +20,3 @@ {

"main": "./index.js",
"version": "8.0.15",
"version": "8.0.16",
"license": "MIT",

@@ -23,0 +23,0 @@ "repository": {

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc