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

@adactive/adsum-utils

Package Overview
Dependencies
Maintainers
5
Versions
126
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@adactive/adsum-utils - npm Package Compare versions

Comparing version 0.0.2-y.44.43 to 0.0.2-y.44.44

index.js

5

package.json
{
"name": "@adactive/adsum-utils",
"version": "0.0.2-y.44.43",
"version": "0.0.2-y.44.44",
"description": "Adsum Component utils",

@@ -24,3 +24,4 @@ "main": "index.js",

"redux"
]
],
"gitHead": "0c26c3be05d7c2f7dbe82d8d6f68b6ec1c528e0f"
}

34

services/ClientAPI.js

@@ -13,17 +13,25 @@ // @flow

async init(config, fallbackOnlineApi=false) {
const {
endpoint, key, site, username
} = config;
async init(config) {
const { endpoint, key, site, username } = config;
const entityManagerOptions = {
endpoint,
site,
username,
key
};
if (!fallbackOnlineApi) {
entityManagerOptions.cacheManager = new DistCacheManager('//localhost:9001/local');
this.entityManager = new EntityManager({
endpoint,
site,
username,
key,
cacheManager: new DistCacheManager('/local'),
});
}
async load(cacheFirst = true, allowOutdatedCache = true) {
if (cacheFirst) {
return this.entityManager.loadFromCache(allowOutdatedCache)
.catch(() => {
console.warn('ClientAPI: no cache, failling back on live API');
return this.entityManager.load();
});
}
this.entityManager = new EntityManager(entityManagerOptions);
return this.entityManager.load();
}

@@ -30,0 +38,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