js-stellar-base/src/operations/end_sponsoring_future_reserves.js

  1. import xdr from '../xdr';
  2. /**
  3. * Create an "end sponsoring future reserves" operation.
  4. * @function
  5. * @alias Operation.endSponsoringFutureReserves
  6. * @param {object} opts Options object
  7. * @param {string} [opts.source] - The source account for the operation. Defaults to the transaction's source account.
  8. * @returns {xdr.Operation} xdr operation
  9. *
  10. * @example
  11. * const op = Operation.endSponsoringFutureReserves();
  12. *
  13. */
  14. export function endSponsoringFutureReserves(opts = {}) {
  15. const opAttributes = {};
  16. opAttributes.body = xdr.OperationBody.endSponsoringFutureReserves();
  17. this.setSourceAccount(opAttributes, opts);
  18. return new xdr.Operation(opAttributes);
  19. }