Remove outdated gravatar-related columns from sql query
authorMarcel Werk <burntime@woltlab.com>
Tue, 16 Aug 2022 12:25:43 +0000 (14:25 +0200)
committerMarcel Werk <burntime@woltlab.com>
Tue, 16 Aug 2022 12:25:43 +0000 (14:25 +0200)
files/lib/system/exporter/IPB3xExporter.class.php
files/lib/system/exporter/IPB4xExporter.class.php
files/lib/system/exporter/NodeBB0xRedisExporter.class.php
files/lib/system/exporter/WBB3xExporter.class.php
files/lib/system/exporter/WBB4xExporter.class.php

index b1c98216e677d78f0fde527cfbad46e790d11aa1..b55d9b98c42e73ee9fd0cc1ea565feb9cbc4bd81 100644 (file)
@@ -250,7 +250,6 @@ class IPB3xExporter extends AbstractExporter
                 'registrationDate' => $row['joined'],
                 'banned' => $row['member_banned'],
                 'registrationIpAddress' => UserUtil::convertIPv4To6($row['ip_address']),
-                'enableGravatar' => (!empty($row['pp_gravatar']) && $row['pp_gravatar'] == $row['email']) ? 1 : 0,
                 'signature' => self::fixMessage($row['signature']),
                 'profileHits' => $row['members_profile_views'],
                 'userTitle' => $row['title'] ?: '',
index 62eff8da779144a5d6d2518e4cf9ebc8d57bd584..6177baf6818c6ca7ae9c615ffdbd54e95c7e16bf 100644 (file)
@@ -306,7 +306,6 @@ class IPB4xExporter extends AbstractExporter
                 'registrationDate' => $row['joined'],
                 'banned' => $row['temp_ban'] == -1 ? 1 : 0,
                 'registrationIpAddress' => UserUtil::convertIPv4To6($row['ip_address']),
-                'enableGravatar' => (!empty($row['pp_gravatar']) && $row['pp_gravatar'] == $row['email']) ? 1 : 0,
                 'signature' => self::fixMessage($row['signature']),
                 'profileHits' => $row['members_profile_views'],
                 'userTitle' => $row['member_title'] ?: '',
index 5ade6db21bc2b0ef6c00f7d0fc972aedcc564ca0..42878725bb0d40af269a3c9823aa532480ce5fb8 100644 (file)
@@ -195,19 +195,6 @@ class NodeBB0xRedisExporter extends AbstractExporter
                 'signature' => self::convertMarkdown($row['signature']),
             ];
 
-            static $gravatarRegex = null;
-            if ($gravatarRegex === null) {
-                $gravatarRegex = new Regex('https://(?:secure\.)?gravatar\.com/avatar/([a-f0-9]{32})');
-            }
-
-            if ($gravatarRegex->match($row['picture'])) {
-                $matches = $gravatarRegex->getMatches();
-
-                if ($matches[1] === \md5($row['email'])) {
-                    $data['enableGravatar'] = 1;
-                }
-            }
-
             $birthday = \DateTime::createFromFormat('m/d/Y', StringUtil::decodeHTML($row['birthday']));
             // get user options
             $options = [
index 44c879bbcf1754f2dfc9cef5be8773bfb951baa2..db2fd780d7136ecd098eca1ed52e227fe5674d2c 100644 (file)
@@ -531,7 +531,6 @@ class WBB3xExporter extends AbstractExporter
                 'registrationIpAddress' => UserUtil::convertIPv4To6($row['registrationIpAddress']),
                 'disableAvatar' => $row['disableAvatar'],
                 'disableAvatarReason' => !empty($row['disableAvatarReason']) ? $row['disableAvatarReason'] : '',
-                'enableGravatar' => (!empty($row['gravatar']) && $row['gravatar'] == $row['email']) ? 1 : 0,
                 'signature' => $row['signature'],
                 'signatureEnableHtml' => $row['enableSignatureHtml'],
                 'disableSignature' => $row['disableSignature'],
index 95e81527dd43d2678035a1d49d3cf4760e6d1a62..c46f421c61c079c5b298bf65d31aed781e71774f 100644 (file)
@@ -632,7 +632,6 @@ class WBB4xExporter extends AbstractExporter
                 'registrationIpAddress' => $row['registrationIpAddress'],
                 'disableAvatar' => $row['disableAvatar'],
                 'disableAvatarReason' => $row['disableAvatarReason'],
-                'enableGravatar' => $row['enableGravatar'],
                 'signature' => $row['signature'],
                 'signatureEnableHtml' => $row['signatureEnableHtml'],
                 'disableSignature' => $row['disableSignature'],