diff --git a/packages/foam-vscode/package.json b/packages/foam-vscode/package.json
index b9141f01f..4730dbe7b 100644
--- a/packages/foam-vscode/package.json
+++ b/packages/foam-vscode/package.json
@@ -699,7 +699,7 @@
     "wait-for-expect": "^3.0.2"
   },
   "dependencies": {
-    "dateformat": "^3.0.3",
+    "dateformat": "4.5.1",
     "detect-newline": "^3.1.0",
     "github-slugger": "^1.4.0",
     "gray-matter": "^4.0.2",
diff --git a/yarn.lock b/yarn.lock
index dc2c49100..5f1784644 100644
--- a/yarn.lock
+++ b/yarn.lock
@@ -4425,7 +4425,12 @@ data-urls@^2.0.0:
     whatwg-mimetype "^2.3.0"
     whatwg-url "^8.0.0"
 
-dateformat@^3.0.0, dateformat@^3.0.3:
+dateformat@4.5.1:
+  version "4.5.1"
+  resolved "https://registry.yarnpkg.com/dateformat/-/dateformat-4.5.1.tgz#c20e7a9ca77d147906b6dc2261a8be0a5bd2173c"
+  integrity sha512-OD0TZ+B7yP7ZgpJf5K2DIbj3FZvFvxgFUuaqA/V5zTjAtAAXZ1E8bktHxmAGs4x5b7PflqA9LeQ84Og7wYtF7Q==
+
+dateformat@^3.0.0:
   version "3.0.3"
   resolved "https://registry.yarnpkg.com/dateformat/-/dateformat-3.0.3.tgz#a6e37499a4d9a9cf85ef5872044d62901c9889ae"
   integrity sha512-jyCETtSl3VMZMWeRo7iY1FL19ges1t55hMo5yaam4Jrsm5EPL89UQkoQRyiI+Yf4k8r2ZpdngkV8hr1lIdjb3Q==