From ddcabfc1556199c1df921cd694aa90ed75a4d771 Mon Sep 17 00:00:00 2001 From: Said Achmiz Date: Sun, 12 Dec 2021 14:39:05 -0500 Subject: [PATCH] Minor fix --- versioned-assets.php | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/versioned-assets.php b/versioned-assets.php index 2e4203b..7206bb1 100644 --- a/versioned-assets.php +++ b/versioned-assets.php @@ -5,7 +5,7 @@ * \brief Adds versions (modification timestamps) to attachment URLs, so that browser * caches invalidate properly when attachments are updated. */ -$RecipeInfo['VersionedAssets']['Version'] = '2017-12-13'; +$RecipeInfo['VersionedAssets']['Version'] = '2021-12-12'; global $LinkFunctions; $LinkFunctions['Attach:'] = 'LinkUploadVersioned'; @@ -42,10 +42,9 @@ function LinkUploadVersioned($pagename, $imap, $path, $alt, $txt, $fmt=NULL) { global $VersionedAssetsReattachFileExtension; if ($VersionedAssetsReattachFileExtension == true) { ## Re-attach the file extension, so that LinkIcons and such things work properly. - preg_match("/\\.[^\\.]+$/", $path, $matches); + preg_match('/\.[^\.]+$/', $path, $matches); $versioned_path .= $matches[0]; } return LinkIMap($pagename, $imap, $versioned_path, $alt, $txt, $fmt); -} - +} \ No newline at end of file -- 2.11.4.GIT