Handle null fingerprints properly.

This commit is contained in:
Andrew Bayer 2013-09-27 15:29:56 -07:00
parent f7ac63bdeb
commit d4abfec8aa
1 changed files with 2 additions and 0 deletions

View File

@ -241,6 +241,8 @@ public class GoogleComputeEngineParserModule extends AbstractModule {
String fingerprint = null;
if (metadata.getAsJsonPrimitive("fingerprint") != null) {
fingerprint = metadata.getAsJsonPrimitive("fingerprint").getAsString();
} else {
fingerprint = "";
}
return new Metadata(fingerprint, builder.build());
}