From b319bb33977b7fafbf18139d8a6a6f752c041e0a Mon Sep 17 00:00:00 2001 From: joshuaruesweg Date: Thu, 4 Mar 2021 20:01:53 +0100 Subject: [PATCH] Fix codestyle --- .../install/files/acp/database/update_com.woltlab.wcf_5.4.php | 4 ++-- .../system/background/job/UnfurlUrlBackgroundJob.class.php | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/wcfsetup/install/files/acp/database/update_com.woltlab.wcf_5.4.php b/wcfsetup/install/files/acp/database/update_com.woltlab.wcf_5.4.php index a5e4fe7691..17d7f93153 100644 --- a/wcfsetup/install/files/acp/database/update_com.woltlab.wcf_5.4.php +++ b/wcfsetup/install/files/acp/database/update_com.woltlab.wcf_5.4.php @@ -1,7 +1,7 @@ defaultValue('PENDING'), NotNullInt10DatabaseTableColumn::create('lastFetch') - ->defaultValue(0) + ->defaultValue(0), ]) ->indices([ DatabaseTablePrimaryIndex::create() diff --git a/wcfsetup/install/files/lib/system/background/job/UnfurlUrlBackgroundJob.class.php b/wcfsetup/install/files/lib/system/background/job/UnfurlUrlBackgroundJob.class.php index 2aed901679..7dd5bb933e 100644 --- a/wcfsetup/install/files/lib/system/background/job/UnfurlUrlBackgroundJob.class.php +++ b/wcfsetup/install/files/lib/system/background/job/UnfurlUrlBackgroundJob.class.php @@ -69,6 +69,7 @@ final class UnfurlUrlBackgroundJob extends AbstractBackgroundJob if (empty(StringUtil::trim($unfurlResponse->getTitle()))) { $this->save(UnfurlUrl::STATUS_REJECTED); + return; } @@ -173,7 +174,7 @@ final class UnfurlUrlBackgroundJob extends AbstractBackgroundJob throw new DownloadFailed(); } - $imageHash = sha1($image); + $imageHash = \sha1($image); $path = WCF_DIR . 'images/unfurlUrl/' . \substr($imageHash, 0, 2); FileUtil::makePath($path); -- 2.20.1