class GVIVE::Identity::Voter
Public Class Methods
new(voter_id, photo = false)
click to toggle source
Voter
ID number required Optionally specify whether you want to return a Base64Encoded Photo @param [String] voter_id @param [Boolean] photo
Calls superclass method
GVIVE::Identities::new
# File lib/gvive/identity/voter.rb, line 9 def initialize(voter_id, photo = false) super(voter_id, photo) end
Public Instance Methods
valid?()
click to toggle source
Implementing valid? method signature as described in Identity
Class
# File lib/gvive/identity/voter.rb, line 14 def valid? params = id_params({ vid: @id }) # Voter ID does not include signature photo request # Let's remove this from the API request call params.delete(:incs) @response = gvive_request(voter_endpoint, params) @data = @response.to_o @response.success? end