ru.Bee 2.7.14 → 2.7.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/db/test.db +0 -0
- data/lib/rubee/models/sequel_object.rb +12 -0
- data/lib/rubee.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 60d76c4c74e1ef25002822bd6a85b82ca622cec1725632a110ee53f46d71d23a
|
|
4
|
+
data.tar.gz: 9ec77780e934c56f139f0f765a1fa631bd6bad7b68894701c589cbd10a75bef6
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: a45bbf711fc7be24f49a8315f14c5af794d1ace97ee974a15e466e4feb5b6d904be16695ebf9252f640f6a6c97f9bc771085edd53b97a88f7317ee09e2246981
|
|
7
|
+
data.tar.gz: c4d35b51ed0bc20c08364e5e072f1fd9ad04eea690d3e55fa243898d11fee500adbb1a6c96eb0e489fc720d6dc43ac54d96e6647911ee3e7ba123daefe3e39fb
|
data/lib/db/test.db
CHANGED
|
Binary file
|
|
@@ -174,6 +174,18 @@ module Rubee
|
|
|
174
174
|
false
|
|
175
175
|
end
|
|
176
176
|
|
|
177
|
+
def force_disconnect!
|
|
178
|
+
return unless db_set?
|
|
179
|
+
|
|
180
|
+
DB.disconnect
|
|
181
|
+
Object.send(:remove_const, :DB)
|
|
182
|
+
end
|
|
183
|
+
|
|
184
|
+
def force_reconnect!
|
|
185
|
+
force_disconnect!
|
|
186
|
+
const_set(:DB, Sequel.connect(Rubee::Configuration.get_database_url))
|
|
187
|
+
end
|
|
188
|
+
|
|
177
189
|
def db_set?
|
|
178
190
|
defined?(DB) && !DB.nil?
|
|
179
191
|
end
|
data/lib/rubee.rb
CHANGED