Skip to content

Commit

Permalink
Merge pull request #49 from southbridgeio/develop
Browse files Browse the repository at this point in the history
Develop
  • Loading branch information
vladislav-yashin authored Jun 29, 2021
2 parents 5d809ba + 4f156ee commit e6de2c0
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
8 changes: 8 additions & 0 deletions ChangeLog.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
### 3.0.1 / 2020-06-29

* Fix client dispose

### 3.0.0 / 2020-06-28

* Extract schema to separate gem

### 2.1.0 / 2019-10-18

* Support tdlib 1.5
Expand Down
3 changes: 2 additions & 1 deletion lib/tdlib/client.rb
Original file line number Diff line number Diff line change
Expand Up @@ -167,9 +167,10 @@ def ready?
private

def handle_update(update)
return unless update.is_a?(TD::Types::AuthorizationState::Closed)
return unless update.is_a?(TD::Types::Update::AuthorizationState) && update.authorization_state.is_a?(TD::Types::AuthorizationState::Closed)
@alive = false
@ready = false
sleep 0.001
TD::Api.client_destroy(@td_client)
throw(:client_closed)
end
Expand Down

0 comments on commit e6de2c0

Please sign in to comment.