]> 91.132.146.200 Git - insipid.git/commitdiff
fixed #13
authorBanana <mail@bananas-playground.net>
Sat, 28 May 2022 17:13:06 +0000 (19:13 +0200)
committerBanana <mail@bananas-playground.net>
Sat, 28 May 2022 17:13:06 +0000 (19:13 +0200)
ChangeLog
webroot/view/editcategories.inc.php
webroot/view/edittags.inc.php

index bc3bf7e61b0b782e5f2cf558ab900083dc16185a..44f3dd433ede2da796164eb888f3f640e66418d6 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -7,6 +7,8 @@ version 2.7 - Sacred Grove ()
        + Added random link page
        + New syntax in config file. See update.txt for more details
        + Fixed #13
+       + Fixed #15
+       # Fixed #14
 
 version 2.6 - Hypostyle (2021-03-21)
 
index dbeeef85384a5683f3ccb15a77bde2867011215b..f38b2408d2d44cd5317a6ff298a16f290d34bfdd 100644 (file)
@@ -63,6 +63,10 @@ if(isset($_POST['category']) && !empty($_POST['category']) && isset($_POST['upda
             $catObjAlternative = new Category($DB);
             $do = $catObjAlternative->initbystring($v,true);
             if($do === 1) { # existing
+                               if($k == $catObjAlternative->getData('id')) {
+                                       // Rename to the same. Do nothing
+                                       continue;
+                               }
                 // the target cat should not be removed!
                 $catDoNotDeleteFromUpdate[$catObjAlternative->getData('id')] = $catObjAlternative->getData('id');
                 $catObjOld = new Category($DB);
index 03a60ad41f3ff32bde52fdc28233bc6d69826e93..eb40228e9d0d885cb6e5dfd300957b55e7d9cc5e 100644 (file)
@@ -63,6 +63,10 @@ if(isset($_POST['tag']) && !empty($_POST['tag']) && isset($_POST['updateTags']))
             $tagObjAlternative = new Tag($DB);
             $do = $tagObjAlternative->initbystring($v,true);
             if($do === 1) { # existing
+                               if($k == $tagObjAlternative->getData('id')) {
+                                       // Rename to the same. Do nothing
+                                       continue;
+                               }
                 // the target tag should not be removed!
                 $tagDoNotDeleteFromUpdate[$tagObjAlternative->getData('id')] = $tagObjAlternative->getData('id');
                 $tagObjOld = new Tag($DB);