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

convert-slow-api

Package Overview
Dependencies
Maintainers
1
Versions
12
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

convert-slow-api - npm Package Compare versions

Comparing version 1.0.5 to 1.0.6

13

dist/get-router.js

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

var _ref2 = (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee2(req, res) {
var id, cacheKey, cached;
var id, cacheKey, cached, finished;
return _regenerator["default"].wrap(function _callee2$(_context2) {

@@ -132,6 +132,13 @@ while (1) {

res.json(cached);
_context2.next = 13;
finished = cached.finished;
if (!finished) {
_context2.next = 15;
break;
}
_context2.next = 15;
return _cache["default"].del(cacheKey);
case 13:
case 15:
case "end":

@@ -138,0 +145,0 @@ return _context2.stop();

{
"name": "convert-slow-api",
"version": "1.0.5",
"version": "1.0.6",
"description": "",

@@ -5,0 +5,0 @@ "main": "dist/get-router.js",

@@ -49,7 +49,13 @@ import { Router } from 'express'

let cached = await cache.get(cacheKey)
if (!cached) return res.json({
error: `id=${id} job not found`,
})
res.json(cached)
await cache.del(cacheKey)
const { finished } = cached
if (finished) {
await cache.del(cacheKey)
}
})

@@ -56,0 +62,0 @@

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