From 94ceabb732740dca1f9438e4a111000506e51314 Mon Sep 17 00:00:00 2001 From: Alan Orth Date: Fri, 31 Jul 2020 22:26:50 +0300 Subject: [PATCH] Close BufferedReader after we use it --- src/main/java/org/cgiar/cgspace/ctasks/CountryCodeTagger.java | 1 + 1 file changed, 1 insertion(+) diff --git a/src/main/java/org/cgiar/cgspace/ctasks/CountryCodeTagger.java b/src/main/java/org/cgiar/cgspace/ctasks/CountryCodeTagger.java index 90bdb2d..5450ba5 100644 --- a/src/main/java/org/cgiar/cgspace/ctasks/CountryCodeTagger.java +++ b/src/main/java/org/cgiar/cgspace/ctasks/CountryCodeTagger.java @@ -79,6 +79,7 @@ public class CountryCodeTagger extends AbstractCurationTask reader = new BufferedReader(new InputStreamReader(this.getClass().getResourceAsStream(cgspaceCountriesJsonPath))); CountriesVocabulary cgspaceCountriesJson = gson.fromJson(reader, CountriesVocabulary.class); + reader.close(); System.out.println(isocodesCountriesJson.getClass()); System.out.println(cgspaceCountriesJson.getClass());