selfsdk 0.0.210 → 0.0.211

Sign up to get free protection for your applications and to get access to all the features.
Files changed (4) hide show
  1. checksums.yaml +4 -4
  2. data/lib/crypto.rb +1 -0
  3. data/lib/messaging.rb +4 -1
  4. metadata +1 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 97a576e450b5c015dd14fdac839bdffa8de9a3f6d5fdcda6f9c09970a9a11e63
4
- data.tar.gz: 02eb35df5ad3fb4609ad5b91704c8085b74532434ca94c458d88fa1f35e62aa9
3
+ metadata.gz: 2a1963ba30a0e3805ba038837fc8c4cbdabea43463faf7682ae7562b0aae230d
4
+ data.tar.gz: 128af12164985e2cfd838b6d00e847be098739ce2a67152f000b34cf700e73ea
5
5
  SHA512:
6
- metadata.gz: 01335ef6d7e1afcc0abcd3e74d3ff15073ba24b13442475374e28263c02e7a5ba3c2face85ac3140aa8dee54bedb54f81ae0d0a1acfc28c40cb24177e5021456
7
- data.tar.gz: 344a4b3becca938ff1c23dbe9b29216c7e04d2c31d3bfc986a8bdec3421b94c5ae434bbbec18a3abd071ec17d95cf4a22c841ec3607ce7e979df69c7cb644ca6
6
+ metadata.gz: 39ecffbd49ffb189b63754779d8057876171abe70311b5603e10391ef5240b3f591e6a54dbfce76cab3bef46d19f0be2907542d1f649a2d9a32cfe3d287beede
7
+ data.tar.gz: f6dbe1b68052d3f7eb17983d5ec6bdf966e9d87644c503855402f9cf841a3c92906e29825f2d3192374f24e81858763943947170a909a0b370fa275a3aa50b27
data/lib/crypto.rb CHANGED
@@ -30,6 +30,7 @@ module SelfSDK
30
30
  raise 'unable to push prekeys, please try in a few minutes' if res.code != 200
31
31
 
32
32
  # 1b-v) store the account to a file
33
+ FileUtils.mkdir_p(@storage_folder)
33
34
  File.write(account_path, @account.to_pickle(storage_key))
34
35
  end
35
36
  end
data/lib/messaging.rb CHANGED
@@ -67,7 +67,6 @@ module SelfSDK
67
67
  # This is kind of a hack to catch some corner cases where
68
68
  # the websocket client is not aware it has been disconnected.
69
69
  def ping
70
- SelfSDK.logger.debug "ping"
71
70
  @ws.ping 'ping'
72
71
  end
73
72
 
@@ -192,6 +191,10 @@ module SelfSDK
192
191
  end
193
192
  end
194
193
 
194
+ def close
195
+ @ws.close
196
+ end
197
+
195
198
  # Checks if the session with a specified identity / device is already created.
196
199
  def session?(identifier, device)
197
200
  path = @encryption_client.session_path(identifier, device)
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: selfsdk
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.210
4
+ version: 0.0.211
5
5
  platform: ruby
6
6
  authors:
7
7
  - Self Group Ltd.