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

meddelare-server

Package Overview
Dependencies
Maintainers
1
Versions
22
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

meddelare-server - npm Package Compare versions

Comparing version 1.3.0 to 1.3.1

13

lib/social-buttons-server-middleware.js

@@ -8,3 +8,4 @@ var express = require("express");

var LOCAL_CACHE_TIME_GOOD_RESULT = 4 * 60 * 1000,
LOCAL_CACHE_TIME_BAD_RESULT = 1 * 60 * 1000;
LOCAL_CACHE_TIME_BAD_RESULT = 1 * 60 * 1000,
LOCAL_CACHE_TIME_TIMEOUT_RESULT = 10 * 1000;

@@ -144,3 +145,6 @@ // Return this count if none was found or an error was thrown.

return retrieveCount(url, network)
// If the lookup yielded no result, kick off a request and put it in the cache for now.
// This way the .resolve(cache) call above makes sure multiple requests count requests
// for the same network/url cannot be sent at the same time.
var retrieveCountPromise = retrieveCount(url, network)
.tap(function(uncachedResult) {

@@ -158,2 +162,7 @@ console.log(cacheKey, "fetched good result", uncachedResult);

});
// Setting a cache timeout just in case, even though it can lead to parallel requests.
cache.put(cacheKey, retrieveCountPromise, LOCAL_CACHE_TIME_TIMEOUT_RESULT);
return retrieveCountPromise;
});

@@ -160,0 +169,0 @@ }

2

package.json
{
"name": "meddelare-server",
"version": "1.3.0",
"version": "1.3.1",
"description": "Install custom social share counters on your website with your own hosted solution, which only makes a single API request and loads minimal or zero assets to display the counters.",

@@ -5,0 +5,0 @@ "homepage": "http://meddelare.com/",

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