Skip to content

Commit

Permalink
Use StringHelper::encodeMb4() instead
Browse files Browse the repository at this point in the history
Signed-off-by: Andrew Welch <andrew@nystudio107.com>
  • Loading branch information
khalwat committed Sep 29, 2017
1 parent 76f90e8 commit 9d049c8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions services/RetourService.php
Original file line number Diff line number Diff line change
Expand Up @@ -374,8 +374,8 @@ public function incrementStatistics($url, $handled = false)

if (empty($result)) {
$stats = new Retour_StatsRecord;
$stats->redirectSrcUrl = preg_replace('/[\x{10000}-\x{10FFFF}]/u', "\xEF\xBF\xBD", $url);
$stats->referrerUrl = preg_replace('/[\x{10000}-\x{10FFFF}]/u', "\xEF\xBF\xBD", $referrer);
$stats->redirectSrcUrl = StringHelper::encodeMb4($url);
$stats->referrerUrl = StringHelper::encodeMb4($referrer);
$stats->hitCount = 1;
$stats->hitLastTime = DateTimeHelper::currentUTCDateTime();
$stats->handledByRetour = $handled;
Expand Down

0 comments on commit 9d049c8

Please sign in to comment.