atipugin / telegram-bot-ruby

Ruby wrapper for Telegram's Bot API
https://core.telegram.org/bots/api
Do What The F*ck You Want To Public License
1.35k stars 217 forks source link

Rename `Bot::Api#conn` to `#connection` and make it public #289

Closed AlexWayfer closed 1 year ago

AlexWayfer commented 1 year ago

I see no reason to shrink it's like this.

Also I'm thinking to make it's public: can be helpful for adding middlewares, such as :logger, but maybe I'll consider changes to the Bot::Configuration later.


Update: I've decided to make it public, because don't know how to add connection.response :logger, nil, { headers: true, bodies: true } into Configuration with flexible customization. It seems just easier to call connection from outside as you want.