Commit 93a7af32 authored by Riegel's avatar Riegel
Browse files

Fix: Correct ZipEntry name parsing

Showing with 4 additions and 4 deletions
+4 -4
......@@ -32,7 +32,7 @@ public class CityGmlZipEntry {
try {
CityGmlParser.gagLogger(true);
CityDoctorModel model = CityGmlParser.parseCityGmlZipEntry(entry, archive, config);
return new CityGmlZipEntry(entry.getName(), model);
return new CityGmlZipEntry(entry, model);
} catch (CityGmlParseException | InvalidGmlFileException e) {
logger.error(e);
return new ErroneousEntry(entry, ZipEntryErrorType.INVALID_CITY_GML_FILE);
......@@ -43,13 +43,13 @@ public class CityGmlZipEntry {
}
}
private CityGmlZipEntry(String filename, CityDoctorModel model){
this.fileName = filename;
private CityGmlZipEntry(ZipEntry entry, CityDoctorModel model){
this.fileName = entry.getName().substring(entry.getName().lastIndexOf('/') + 1);
this.model = model;
}
protected CityGmlZipEntry(ZipEntry entry) {
this.fileName = entry.getName();
this.fileName = entry.getName().substring(entry.getName().lastIndexOf('/') + 1);
this.model = null;
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment