aboutsummaryrefslogtreecommitdiffhomepage
path: root/index.php
diff options
context:
space:
mode:
authorArthurHoaro <arthur@hoa.ro>2018-08-16 17:25:47 +0200
committerArthurHoaro <arthur@hoa.ro>2018-08-16 17:25:47 +0200
commit4fa9a3c5d83a1024678596a586afe5df14a345b5 (patch)
tree1f4facd10b9fda91a252e3d35c5fd79c47c3081d /index.php
parentf28b73b21f705102f8536cd16ea28122aa870e49 (diff)
downloadShaarli-4fa9a3c5d83a1024678596a586afe5df14a345b5.tar.gz
Shaarli-4fa9a3c5d83a1024678596a586afe5df14a345b5.tar.zst
Shaarli-4fa9a3c5d83a1024678596a586afe5df14a345b5.zip
Fix a JS bug preventing AJAX tag deletion to work
Fixes #1214
Diffstat (limited to 'index.php')
-rw-r--r--index.php3
1 files changed, 2 insertions, 1 deletions
diff --git a/index.php b/index.php
index 8f6ee50a..eb717536 100644
--- a/index.php
+++ b/index.php
@@ -1084,7 +1084,8 @@ function renderPage($conf, $pluginManager, $LINKSDB, $history, $sessionManager,
1084 die(t('Wrong token.')); 1084 die(t('Wrong token.'));
1085 } 1085 }
1086 1086
1087 $alteredLinks = $LINKSDB->renameTag(escape($_POST['fromtag']), escape($_POST['totag'])); 1087 $toTag = isset($_POST['totag']) ? escape($_POST['totag']) : null;
1088 $alteredLinks = $LINKSDB->renameTag(escape($_POST['fromtag']), $toTag);
1088 $LINKSDB->save($conf->get('resource.page_cache')); 1089 $LINKSDB->save($conf->get('resource.page_cache'));
1089 foreach ($alteredLinks as $link) { 1090 foreach ($alteredLinks as $link) {
1090 $history->updateLink($link); 1091 $history->updateLink($link);