From 6cabb2e9351c438f4bd99129f8ddfc1f48368c31 Mon Sep 17 00:00:00 2001 From: Elliot Lee Date: Tue, 28 Apr 2020 14:34:49 -0700 Subject: [PATCH] Release 1.7.0 --- docs/index.md | 1 + package.json | 2 +- src/transaction/submit.ts | 7 +++++-- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/docs/index.md b/docs/index.md index c8c63300..5732617f 100644 --- a/docs/index.md +++ b/docs/index.md @@ -5600,6 +5600,7 @@ Submits a signed transaction. The transaction is not guaranteed to succeed; it m Name | Type | Description ---- | ---- | ----------- signedTransaction | string | A signed transaction as returned by [sign](#sign). +failHard | boolean | *Optional* If `true`, and the transaction fails locally, do not retry or relay the transaction to other servers. Defaults to `false`. ### Return Value diff --git a/package.json b/package.json index e52a11eb..105e7b3e 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "ripple-lib", - "version": "1.6.6-beta.2", + "version": "1.7.0", "license": "ISC", "description": "A TypeScript/JavaScript API for interacting with the XRP Ledger in Node.js and the browser", "files": [ diff --git a/src/transaction/submit.ts b/src/transaction/submit.ts index 011e2380..5e326287 100644 --- a/src/transaction/submit.ts +++ b/src/transaction/submit.ts @@ -39,12 +39,15 @@ function formatSubmitResponse(response): FormattedSubmitResponse { async function submit( this: RippleAPI, signedTransaction: string, - failHard?: boolean + failHard?: boolean ): Promise { // 1. Validate validate.submit({signedTransaction}) // 2. Make Request - const response = await this.request('submit', {tx_blob: signedTransaction, ...(failHard ? {fail_hard: failHard} : {})}) + const response = await this.request('submit', { + tx_blob: signedTransaction, + ...(failHard ? {fail_hard: failHard} : {}) + }) // 3. Return Formatted Response return formatSubmitResponse(response) }