Skip to content

Commit

Permalink
new yapf version, new cosmetic fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
tsnoam committed Jun 18, 2016
1 parent 494a7ec commit 5b91194
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 18 deletions.
24 changes: 13 additions & 11 deletions telegram/bot.py
Expand Up @@ -618,13 +618,14 @@ def sendLocation(self, chat_id, latitude, longitude, **kwargs):

@log
@message
def sendVenue(
self, chat_id,
latitude,
longitude,
title, address,
foursquare_id=None,
**kwargs):
def sendVenue(self,
chat_id,
latitude,
longitude,
title,
address,
foursquare_id=None,
**kwargs):
"""
Use this method to send information about a venue.
Expand Down Expand Up @@ -1132,10 +1133,11 @@ def editMessageCaption(self,

@log
@message
def editMessageReplyMarkup(
self, chat_id=None,
message_id=None, inline_message_id=None,
**kwargs):
def editMessageReplyMarkup(self,
chat_id=None,
message_id=None,
inline_message_id=None,
**kwargs):
"""Use this method to edit only the reply markup of messages sent by
the bot or via the bot (for inline bots).
Expand Down
7 changes: 3 additions & 4 deletions telegram/ext/updater.py
Expand Up @@ -285,10 +285,9 @@ def _start_webhook(self, listen, port, url_path, cert, key, bootstrap_retries, c
def _check_ssl_cert(self, cert, key):
# Check SSL-Certificate with openssl, if possible
try:
exit_code = subprocess.call(
["openssl", "x509", "-text", "-noout", "-in", cert],
stdout=open(os.devnull, 'wb'),
stderr=subprocess.STDOUT)
exit_code = subprocess.call(["openssl", "x509", "-text", "-noout", "-in", cert],
stdout=open(os.devnull, 'wb'),
stderr=subprocess.STDOUT)
except OSError:
exit_code = 0
if exit_code is 0:
Expand Down
6 changes: 3 additions & 3 deletions telegram/inputfile.py
Expand Up @@ -125,9 +125,9 @@ def to_form(self):

# Add input_file to upload
form.extend([
form_boundary, 'Content-Disposition: form-data; name="%s"; filename="%s"' % (
self.input_name, self.filename
), 'Content-Type: %s' % self.mimetype, '', self.input_file_content
form_boundary, 'Content-Disposition: form-data; name="%s"; filename="%s"' %
(self.input_name, self.filename), 'Content-Type: %s' % self.mimetype, '',
self.input_file_content
])

form.append('--' + self.boundary + '--')
Expand Down

0 comments on commit 5b91194

Please sign in to comment.