@bettercms-ai/sdk 1.26.1 → 1.26.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.cts CHANGED
@@ -1487,7 +1487,7 @@ declare function search(opts: SearchOptions): Promise<SearchHit[]>;
1487
1487
  * `import.meta.glob`) and the bundle holds a frozen copy no publish can reach: the platform then
1488
1488
  * has to rebuild the whole site for every edit.
1489
1489
  *
1490
- * - On a hosted server: `BCMS_CONTENT_FILE`, re-read when it changes (checked at most once a second).
1490
+ * - On a hosted server: `BCMS_CONTENT_FILE`, re-read when it changes (its time is asked on every call).
1491
1491
  * - At build time and in local dev: `<cwd>/bcms-content.json`, the snapshot the build was given.
1492
1492
  * - Anywhere without a filesystem (a browser, an edge runtime): `null`.
1493
1493
  *
package/dist/index.d.ts CHANGED
@@ -1487,7 +1487,7 @@ declare function search(opts: SearchOptions): Promise<SearchHit[]>;
1487
1487
  * `import.meta.glob`) and the bundle holds a frozen copy no publish can reach: the platform then
1488
1488
  * has to rebuild the whole site for every edit.
1489
1489
  *
1490
- * - On a hosted server: `BCMS_CONTENT_FILE`, re-read when it changes (checked at most once a second).
1490
+ * - On a hosted server: `BCMS_CONTENT_FILE`, re-read when it changes (its time is asked on every call).
1491
1491
  * - At build time and in local dev: `<cwd>/bcms-content.json`, the snapshot the build was given.
1492
1492
  * - Anywhere without a filesystem (a browser, an edge runtime): `null`.
1493
1493
  *
package/dist/index.js CHANGED
@@ -1568,7 +1568,6 @@ async function search(opts) {
1568
1568
 
1569
1569
  // src/published-content.ts
1570
1570
  var cache = null;
1571
- var checkedAt = 0;
1572
1571
  function publishedContentFile() {
1573
1572
  const proc = globalThis.process;
1574
1573
  if (typeof proc?.getBuiltinModule !== "function") return null;
@@ -1577,9 +1576,6 @@ function publishedContentFile() {
1577
1576
  function readPublishedContent() {
1578
1577
  const file = publishedContentFile();
1579
1578
  if (!file) return null;
1580
- const now = Date.now();
1581
- if (cache && cache.file === file && now - checkedAt < 1e3) return cache.content;
1582
- checkedAt = now;
1583
1579
  const proc = globalThis.process;
1584
1580
  const fs = proc.getBuiltinModule("node:fs");
1585
1581
  try {
@@ -1602,7 +1598,6 @@ function publishedEntry(slug) {
1602
1598
  }
1603
1599
  function resetPublishedContentCache() {
1604
1600
  cache = null;
1605
- checkedAt = 0;
1606
1601
  }
1607
1602
 
1608
1603
  // src/index.ts