]> git.mxchange.org Git - friendica-addons.git/commitdiff
Merge pull request #394 from annando/1612-twitter-media
authorTobias Diekershoff <tobias.diekershoff@gmx.net>
Tue, 13 Dec 2016 22:59:09 +0000 (23:59 +0100)
committerGitHub <noreply@github.com>
Tue, 13 Dec 2016 22:59:09 +0000 (23:59 +0100)
Twitter: Post links with pictures if available

twitter/twitter.php

index 52c99c2976bc875f825df4c139c65a4a8f40a379..934b8d3cec03a9fda1f5ef3ace3a9c022e212d62 100644 (file)
@@ -494,7 +494,8 @@ function twitter_post_hook(&$a,&$b) {
 
                if (isset($msgarr["url"]) AND ($msgarr["type"] != "photo"))
                        $msg .= "\n".$msgarr["url"];
-               elseif (isset($msgarr["image"]) AND ($msgarr["type"] != "video"))
+
+               if (isset($msgarr["image"]) AND ($msgarr["type"] != "video"))
                        $image = $msgarr["image"];
 
                // and now tweet it :-)