Skip to content

Commit 02ac0ee

Browse files
authored
fix: load view in useDatabaseOperations (#70)
1 parent d3ce628 commit 02ac0ee

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/components/app/layers/AppBusinessLayer.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -65,9 +65,6 @@ export const AppBusinessLayer: React.FC<AppBusinessLayerProps> = ({ children })
6565
// Initialize page operations
6666
const pageOperations = usePageOperations({ outline, loadOutline });
6767

68-
// Initialize database operations
69-
const databaseOperations = useDatabaseOperations(loadView, createRowDoc);
70-
7168
// Check if current view has been deleted
7269
const viewHasBeenDeleted = useMemo(() => {
7370
if (!viewId) return false;
@@ -207,6 +204,9 @@ export const AppBusinessLayer: React.FC<AppBusinessLayerProps> = ({ children })
207204
[pageOperations, loadTrash]
208205
);
209206

207+
// Initialize database operations
208+
const databaseOperations = useDatabaseOperations(enhancedLoadView, createRowDoc);
209+
210210
// Business context value
211211
const businessContextValue: BusinessInternalContextType = useMemo(
212212
() => ({

0 commit comments

Comments
 (0)