Generates a permalinks URL if the URL is set to blank

Fixes #926
This commit is contained in:
ArthurHoaro 2017-08-25 20:08:07 +02:00
parent 2a1292359b
commit c27f2f36f2
1 changed files with 3 additions and 0 deletions

View File

@ -1256,6 +1256,9 @@ function renderPage($conf, $pluginManager, $LINKSDB, $history)
// Remove duplicates.
$tags = implode(' ', array_unique(explode(' ', $tags)));
if (empty(trim($_POST['lf_url']))) {
$_POST['lf_url'] = '?' . smallHash($linkdate . $id);
}
$url = whitelist_protocols(trim($_POST['lf_url']), $conf->get('security.allowed_protocols'));
$link = array(