Only overwrite URL if it is similar
This commit is contained in:
parent
2861e4111d
commit
716eb99254
1 changed files with 1 additions and 1 deletions
|
@ -20,7 +20,7 @@ switch ($_SERVER['REQUEST_METHOD']) {
|
|||
$cache = new EmbedCache($_GET['url']);
|
||||
$info = $cache->get(true);
|
||||
|
||||
if ($info->url) {
|
||||
if ($info->url && str_contains($_GET['url'], $info->url)) {
|
||||
$database->query('UPDATE `products`
|
||||
SET `url` = "' . $info->url . '"
|
||||
WHERE `id` = ' . $_GET['product_id'] . '
|
||||
|
|
Loading…
Reference in a new issue