From 05c0fefc01819cc35d82c2fb730dca5ed34b8a7a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Manuel=20Cort=C3=A9z?= Date: Tue, 24 Jan 2017 09:21:19 -0600 Subject: [PATCH] Use get_tweet in ocr function. Fixes #105 --- doc/changelog.md | 1 + src/controller/mainController.py | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/doc/changelog.md b/doc/changelog.md index 9581b75a..ca93f21a 100644 --- a/doc/changelog.md +++ b/doc/changelog.md @@ -3,6 +3,7 @@ ## changes in this version * Fixed a bug in long tweet parsing that was making TWBlue to disconnect the streaming API. [#103](https://github.com/manuelcortez/TWBlue/issues/103) +* Now OCR will work in images from retweets. It fixes a bug where TWBlue was detecting images but couldn't apply OCR on them. [#105](https://github.com/manuelcortez/TWBlue/issues/105) ## Changes in version 0.88 and 0.89 diff --git a/src/controller/mainController.py b/src/controller/mainController.py index 1db1c6e0..1827245c 100644 --- a/src/controller/mainController.py +++ b/src/controller/mainController.py @@ -1527,7 +1527,7 @@ class Controller(object): if hasattr(buffer, "get_right_tweet") == False: output.speak(_(u"Invalid buffer")) return - tweet = buffer.get_right_tweet() + tweet = buffer.get_tweet() if tweet.has_key("entities") == False or tweet["entities"].has_key("media") == False: output.speak(_(u"This tweet doesn't contain images")) return