class MetadataStorageHelper {

    public static JsonNode getUnitFromUnitWithLFC(JsonNode document) {
        if(document == null || !document.hasNonNull(UNIT_KEY)) {
            throw new IllegalArgumentException("Document should contain a "+UNIT_KEY+" object");
        }
        return document.get(UNIT_KEY);
    }

}