Sha256: 7ddd877c69b6fa326f8371c7e14f1440660ac05fe08a22bf7949ce9eacb11673
Contents?: true
Size: 314 Bytes
Versions: 1
Compression:
Stored size: 314 Bytes
Contents
require 'MxnBanks/version' module MxnBanks def self.from_iban(num) a = to_hash.select { |b| b[:number] == num.slice(0, 3) } a.first end def self.to_hash json_file = File.read(File.join(File.dirname(__FILE__), 'banks.json')) @banks ||= JSON.parse(json_file, symbolize_names: true) end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
MxnBanks-0.1.2 | lib/MxnBanks.rb |