codesesh 0.7.0 → 0.7.1

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.
@@ -7680,9 +7680,8 @@ function listFileActivity(options = {}) {
7680
7680
  return [];
7681
7681
  }
7682
7682
  const filters = buildFileActivityWhere(options);
7683
- const rows = withCacheDb(
7684
- (db) => db.prepare(
7685
- `
7683
+ const queryRows = (db) => db.prepare(
7684
+ `
7686
7685
  SELECT
7687
7686
  fa.agent_name,
7688
7687
  fa.session_id,
@@ -7712,8 +7711,11 @@ function listFileActivity(options = {}) {
7712
7711
  ORDER BY fa.latest_time DESC, fa.count DESC, fa.path
7713
7712
  LIMIT ?
7714
7713
  `
7715
- ).all(...filters.params, options.limit ?? 50)
7716
- );
7714
+ ).all(...filters.params, options.limit ?? 50);
7715
+ let rows = withCacheDbReadOnly(queryRows);
7716
+ if (rows == null && options.path) {
7717
+ rows = withCacheDb(queryRows);
7718
+ }
7717
7719
  return (rows ?? []).map((row) => ({
7718
7720
  ...fileActivityFromRow(row),
7719
7721
  session: sessionHeadFromSearchRow(row)
@@ -8555,4 +8557,4 @@ export {
8555
8557
  importBookmarks,
8556
8558
  deleteBookmark
8557
8559
  };
8558
- //# sourceMappingURL=chunk-JTHZVP6G.js.map
8560
+ //# sourceMappingURL=chunk-7GQEIPVK.js.map