Method: Hive::Broadcast.update_proposal_votes

Defined in:
lib/hive/broadcast.rb

.update_proposal_votes(options, &block) ⇒ Object

Parameters:

  • options (Hash)

    options

Options Hash (options):

  • :wif (String)

    Active wif

  • :params (Hash)
    • :voter (String) Account doing approval (or removing approval).

    • :proposal_ids (Array<Integer>) Proposals to approve (or remove approval) for.

    • :approve (Boolean) Approve or unapprove.

  • :pretend (Boolean)

    Just validate, do not broadcast.

See Also:



1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
# File 'lib/hive/broadcast.rb', line 1333

def self.update_proposal_votes(options, &block)
  required_fields = %i(voter proposal_ids approve)
  params = options[:params]
  
  check_required_fields(params, *required_fields)
  
  ops = [[:update_proposal_votes, params]]
  
  process(options.merge(ops: ops), &block)
end