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

frontblock

Package Overview
Dependencies
Maintainers
1
Versions
79
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

frontblock - npm Package Compare versions

Comparing version 0.3.4 to 0.3.5

13

FrontblockApiClient.js

@@ -33,3 +33,4 @@ "use strict";

exportRPCs() {
const unhookFn = async (uid) => { return await this.unsubscribe(this.apikey, uid); };
const unsub = async (uid) => { return await this.unsubscribe(this.apikey, uid); };
const quit = async (uid) => { return await this.quit(this.apikey, uid); };
return [

@@ -45,14 +46,14 @@ {

type: 'hook',
unhook: unhookFn,
unhook: quit,
visibility: 'private'
}, {
name: 'unsubscribe',
rpc: unhookFn,
rpc: unsub,
type: 'unhook',
visibility: 'private'
}, {
name: 'resume',
name: 'consume',
rpc: async (apikey, uid, callback) => { return await this.consume(this.apikey, uid, callback); },
type: 'hook',
unhook: unhookFn,
unhook: quit,
visibility: 'private'

@@ -97,3 +98,3 @@ }

async subsume(apikey, coin, account, callback) {
const r = await this.socket.call("subscribe", apikey, coin, account);
const r = await this.socket.call("subsume", apikey, coin, account);
const res = Types_1.parseSubResponse(r);

@@ -100,0 +101,0 @@ if (res instanceof Types_1.SubscriptionResponse) {

@@ -46,3 +46,4 @@ import { Coin, AccountMap, TransactionMap, SubscriptionResponse, ErrorResponse, SuccessResponse, parseResponse, parseSubResponse } from "frontblock-generic/Types";

exportRPCs(): socketioRPC[] {
const unhookFn = async(uid:string) => { return await this.unsubscribe(this.apikey, uid) }
const unsub = async(uid:string) => { return await this.unsubscribe(this.apikey, uid) }
const quit = async(uid:string) => {return await this.quit(this.apikey, uid) }
return [

@@ -58,14 +59,14 @@ {

type: 'hook',
unhook: unhookFn,
unhook: quit,
visibility: 'private'
},{
name: 'unsubscribe',
rpc: unhookFn,
rpc: unsub,
type: 'unhook',
visibility: 'private'
},{
name: 'resume',
name: 'consume',
rpc: async<C extends Coin>(apikey: string, uid: string, callback: (tx: TransactionMap[C]) => void) => {return await this.consume(this.apikey, uid, callback)},
type: 'hook',
unhook: unhookFn,
unhook: quit,
visibility: 'private'

@@ -116,3 +117,3 @@ }

async subsume<C extends Coin>(apikey: string, coin: C, account: AccountMap[C], callback: (tx: TransactionMap[C]) => void): Promise<SubscriptionResponse | ErrorResponse> {
const r = await this.socket.call("subscribe", apikey, coin, account)
const r = await this.socket.call("subsume", apikey, coin, account)
const res = parseSubResponse(r)

@@ -119,0 +120,0 @@ if(res instanceof SubscriptionResponse){

{
"name": "frontblock",
"version": "0.3.4",
"version": "0.3.5",
"description": "frontblock shop-side library ",

@@ -5,0 +5,0 @@ "scripts": {

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