aboutsummaryrefslogtreecommitdiffhomepage
path: root/index.php
diff options
context:
space:
mode:
authorVirtualTam <virtualtam@flibidi.net>2019-04-15 23:57:08 +0200
committerVirtualTam <virtualtam@flibidi.net>2019-04-15 23:57:08 +0200
commit1cc5eaf9dee0e71aefbce1ff0f28c86ff320c053 (patch)
treec139d7fefc0217b2f18fbb41cb4222879585d3e0 /index.php
parent0ed9396bfa12f086369b52cdc0742e3fe72273ec (diff)
downloadShaarli-1cc5eaf9dee0e71aefbce1ff0f28c86ff320c053.tar.gz
Shaarli-1cc5eaf9dee0e71aefbce1ff0f28c86ff320c053.tar.zst
Shaarli-1cc5eaf9dee0e71aefbce1ff0f28c86ff320c053.zip
backport: Fix a warning if links sticky status isn't set
- initiate its status to false when the link is created - if not defined, initiate its status to false (can happen if the updater hasn't run) This is a backport of https://github.com/shaarli/Shaarli/pull/1270 Original author information: commit b790f900c937d0d8f6eccc15d2b4c26023f3d276 Author: ArthurHoaro <arthur@hoa.ro> Date: Sat Feb 9 14:04:16 2019 +0100 Signed-off-by: VirtualTam <virtualtam@flibidi.net>
Diffstat (limited to 'index.php')
-rw-r--r--index.php2
1 files changed, 2 insertions, 0 deletions
diff --git a/index.php b/index.php
index acfcc660..4deed197 100644
--- a/index.php
+++ b/index.php
@@ -1179,6 +1179,8 @@ function renderPage($conf, $pluginManager, $LINKSDB, $history, $sessionManager,
1179 $link['thumbnail'] = $thumbnailer->get($url); 1179 $link['thumbnail'] = $thumbnailer->get($url);
1180 } 1180 }
1181 1181
1182 $link['sticky'] = isset($link['sticky']) ? $link['sticky'] : false;
1183
1182 $pluginManager->executeHooks('save_link', $link); 1184 $pluginManager->executeHooks('save_link', $link);
1183 1185
1184 $LINKSDB[$id] = $link; 1186 $LINKSDB[$id] = $link;