]> git.immae.eu Git - github/shaarli/Shaarli.git/commitdiff
Fix a bug happening when importing links with override option 861/head
authorArthurHoaro <arthur@hoa.ro>
Sun, 7 May 2017 16:02:49 +0000 (18:02 +0200)
committerArthurHoaro <arthur@hoa.ro>
Sun, 7 May 2017 16:02:49 +0000 (18:02 +0200)
The shorturl would be set to null, generating a lot of warnings and breaking permalinks

application/NetscapeBookmarkUtils.php

index bbfde1386075c42b2deb61a57d8aaed1d39f336b..2a10ff22149f8c89f30458d9e5c907e19847438a 100644 (file)
@@ -180,6 +180,7 @@ class NetscapeBookmarkUtils
                 $newLink['id'] = $existingLink['id'];
                 $newLink['created'] = $existingLink['created'];
                 $newLink['updated'] = new DateTime();
+                $newLink['shorturl'] = $existingLink['shorturl'];
                 $linkDb[$existingLink['id']] = $newLink;
                 $importCount++;
                 $overwriteCount++;