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

@shoutem/api-sdk

Package Overview
Dependencies
Maintainers
4
Versions
39
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@shoutem/api-sdk - npm Package Compare versions

Comparing version 1.0.1-beta.2 to 1.1.0

14

build/lib/services/errors.js

@@ -15,10 +15,12 @@ 'use strict';

function getError(action) {
var errors = _lodash2.default.get(action, ['payload', 'response', 'errors'], []);
return _lodash2.default.get(errors, '0', {});
function getError(response) {
return response.clone().json().then(function (jsonResponse) {
return _lodash2.default.get(jsonResponse, 'errors', []);
});
}
function getErrorCode(action) {
var error = getError(action);
return _lodash2.default.get(error, 'code');
function getErrorCode(response) {
return getError(response).then(function (error) {
return _lodash2.default.get(error, 'code');
});
}
{
"name": "@shoutem/api-sdk",
"version": "1.0.1-beta.2",
"version": "1.1.0",
"description": "Javascript SDK for Shoutem API using fetch",

@@ -5,0 +5,0 @@ "main": "build/lib/index.js",

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