From 256b594f84ae39042bee9cf5e5107e5b13825f84 Mon Sep 17 00:00:00 2001 From: chumv Date: Thu, 9 May 2024 16:17:28 +0300 Subject: [PATCH] Fix possible npe warning --- OsmAnd/src/net/osmand/plus/track/helpers/GpxDbHelper.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/OsmAnd/src/net/osmand/plus/track/helpers/GpxDbHelper.java b/OsmAnd/src/net/osmand/plus/track/helpers/GpxDbHelper.java index 4090e0bf2cc..efc78585ee4 100644 --- a/OsmAnd/src/net/osmand/plus/track/helpers/GpxDbHelper.java +++ b/OsmAnd/src/net/osmand/plus/track/helpers/GpxDbHelper.java @@ -66,8 +66,8 @@ public void loadGpxItems() { items.forEach(item -> { File file = item.getFile(); - if (fileExistenceMap.get(file)) { - dataItems.put(file, item); // putToCache + if (Boolean.TRUE.equals(fileExistenceMap.get(file))) { + dataItems.put(file, item); } else { remove(file); }