ibanizator 0.1.1 → 0.1.2
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/swift_bic/bank_db.rb +3 -2
- metadata +1 -1
data/lib/swift_bic/bank_db.rb
CHANGED
@@ -1,4 +1,5 @@
|
|
1
1
|
require 'sqlite3'
|
2
|
+
require 'ruby-debug'
|
2
3
|
|
3
4
|
module SwiftBic
|
4
5
|
class BankDb
|
@@ -19,7 +20,7 @@ module SwiftBic
|
|
19
20
|
|
20
21
|
def load_table_row bank_number
|
21
22
|
begin
|
22
|
-
db = SQLite3::Database.open("db/blz.db")
|
23
|
+
db = SQLite3::Database.open(File.expand_path("../../../db/blz.db", __FILE__))
|
23
24
|
row = db.execute("SELECT * FROM blz WHERE blz = '#{bank_number}'")
|
24
25
|
rescue SQLite3::Exception => e
|
25
26
|
throw e
|
@@ -29,4 +30,4 @@ module SwiftBic
|
|
29
30
|
row[0]
|
30
31
|
end
|
31
32
|
end
|
32
|
-
end
|
33
|
+
end
|