New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

koishi-plugin-teach

Package Overview
Dependencies
Maintainers
1
Versions
145
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

koishi-plugin-teach - npm Package Compare versions

Comparing version 1.0.0-beta.10 to 1.0.0-beta.11

24

dist/update.js

@@ -34,3 +34,3 @@ "use strict";

return;
const now = Date.now(), includeTime = koishi_utils_1.parseTime(includeLast), excludeTime = koishi_utils_1.parseTime(excludeLast);
const now = Date.now(), includeTime = koishi_utils_1.Time.parseTime(includeLast), excludeTime = koishi_utils_1.Time.parseTime(excludeLast);
const dialogues = Object.values(utils_1.Dialogue.history).filter((dialogue) => {

@@ -63,3 +63,3 @@ if (dialogue._operator !== session.userId)

if (_type) {
output.unshift(`${_type}-${formatTimeShort(Date.now() - _timestamp)}`);
output.unshift(`${_type}-${koishi_utils_1.Time.formatTimeShort(Date.now() - _timestamp)}`);
}

@@ -76,3 +76,3 @@ });

if (_type) {
output.push(`最后一次${_type}于:${koishi_utils_1.formatTime(Date.now() - _timestamp)}前`);
output.push(`最后一次${_type}于:${koishi_utils_1.Time.formatTime(Date.now() - _timestamp)}前`);
}

@@ -84,20 +84,4 @@ });

const n = +value;
return n * 0 === 0 ? !koishi_utils_1.isInteger(n) || n <= 0 : !koishi_utils_1.parseTime(value);
return n * 0 === 0 ? !koishi_utils_1.isInteger(n) || n <= 0 : !koishi_utils_1.Time.parseTime(value);
}
const second = 1000;
const minute = second * 60;
function formatTimeShort(ms) {
let result;
if (ms >= minute - second / 2) {
ms += second / 2;
result = Math.floor(ms / minute) + 'm';
if (ms % minute > second) {
result += Math.floor(ms % minute / second) + 's';
}
}
else {
result = Math.round(ms / second) + 's';
}
return result;
}
function review(dialogues, argv) {

@@ -104,0 +88,0 @@ const { session } = argv;

8

package.json
{
"name": "koishi-plugin-teach",
"description": "Teach plugin for Koishi",
"version": "1.0.0-beta.10",
"version": "1.0.0-beta.11",
"main": "dist/index.js",

@@ -43,8 +43,8 @@ "typings": "dist/index.d.ts",

"koishi-plugin-mysql": "^2.0.0-beta.5",
"koishi-test-utils": "^4.0.0-beta.3"
"koishi-test-utils": "^4.0.0-beta.4"
},
"dependencies": {
"escape-string-regexp": "^4.0.0",
"koishi-core": "^2.0.0-beta.10",
"koishi-utils": "^2.2.0",
"koishi-core": "^2.0.0-beta.11",
"koishi-utils": "^3.0.0",
"leven": "^3.1.0",

@@ -51,0 +51,0 @@ "regexpp": "^3.1.0"

Sorry, the diff of this file is not supported yet

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