From ce0fb75310d86a193c5a754d8c32d2bc0fd1e0d3 Mon Sep 17 00:00:00 2001 From: Dylan Date: Sat, 4 Feb 2023 23:30:10 +0000 Subject: [PATCH] Update dependencies & Combine images by default (#59) * Bump pillow from 9.3.0 to 9.4.0 Bumps [pillow](https://github.com/python-pillow/Pillow) from 9.3.0 to 9.4.0. - [Release notes](https://github.com/python-pillow/Pillow/releases) - [Changelog](https://github.com/python-pillow/Pillow/blob/main/CHANGES.rst) - [Commits](https://github.com/python-pillow/Pillow/compare/9.3.0...9.4.0) --- updated-dependencies: - dependency-name: pillow dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] * Bump boto3 from 1.26.37 to 1.26.45 Bumps [boto3](https://github.com/boto/boto3) from 1.26.37 to 1.26.45. - [Release notes](https://github.com/boto/boto3/releases) - [Changelog](https://github.com/boto/boto3/blob/develop/CHANGELOG.rst) - [Commits](https://github.com/boto/boto3/compare/1.26.37...1.26.45) --- updated-dependencies: - dependency-name: boto3 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] * Bump requests from 2.28.1 to 2.28.2 Bumps [requests](https://github.com/psf/requests) from 2.28.1 to 2.28.2. - [Release notes](https://github.com/psf/requests/releases) - [Changelog](https://github.com/psf/requests/blob/main/HISTORY.md) - [Commits](https://github.com/psf/requests/compare/v2.28.1...v2.28.2) --- updated-dependencies: - dependency-name: requests dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] * Bump boto3 from 1.26.45 to 1.26.64 Bumps [boto3](https://github.com/boto/boto3) from 1.26.45 to 1.26.64. - [Release notes](https://github.com/boto/boto3/releases) - [Changelog](https://github.com/boto/boto3/blob/develop/CHANGELOG.rst) - [Commits](https://github.com/boto/boto3/compare/1.26.45...1.26.64) --- updated-dependencies: - dependency-name: boto3 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] * Combine multiple tweet images by default (#40) --------- Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- requirements.txt | 6 +++--- twitfix.py | 13 +------------ 2 files changed, 4 insertions(+), 15 deletions(-) diff --git a/requirements.txt b/requirements.txt index ad99acf..ffa84fc 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,7 +1,7 @@ pymongo==4.3.3 -boto3==1.26.37 -requests==2.28.1 -Pillow==9.3.0 +boto3==1.26.64 +requests==2.28.2 +Pillow==9.4.0 Flask==2.2.2 Flask-Cors==3.0.10 yt-dlp==2022.7.18 \ No newline at end of file diff --git a/twitfix.py b/twitfix.py index 9703b1a..fc7043e 100644 --- a/twitfix.py +++ b/twitfix.py @@ -78,17 +78,6 @@ def twitfix(sub_path): else: print(" ➤ [ R ] Redirect to MP4 using d.fxtwitter.com") return dir(sub_path) - elif request.url.startswith("https://c.vx") or request.url.endswith('/all'): - twitter_url = sub_path - - if match.start() == 0: - twitter_url = "https://twitter.com/" + sub_path - - if user_agent in generate_embed_user_agents: - return embedCombined(twitter_url) - else: - print(" ➤ [ R ] Redirect to " + twitter_url) - return redirect(twitter_url, 301) elif request.url.endswith(".mp4") or request.url.endswith("%2Emp4"): twitter_url = "https://twitter.com/" + sub_path @@ -122,7 +111,7 @@ def twitfix(sub_path): twitter_url = "https://twitter.com/" + sub_path if user_agent in generate_embed_user_agents: - res = embed_video(twitter_url) + res = embedCombined(twitter_url) return res else: