dispose method
Disposes the persistent cache. Should be called on app shutdown.
Implementation
Future<void> dispose() async {
if (_persistentCache != null) {
try {
await _persistentCache!.close();
_persistentCache = null;
} catch (e) {
debugPrint('Error disposing QueryCache: $e');
}
}
_initialized = false;
_instance = null; // Reset singleton
}