summaryrefslogtreecommitdiff
path: root/src/mbgl/style/parser.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/mbgl/style/parser.cpp')
-rw-r--r--src/mbgl/style/parser.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/mbgl/style/parser.cpp b/src/mbgl/style/parser.cpp
index 52d788b3a1..b177f2159c 100644
--- a/src/mbgl/style/parser.cpp
+++ b/src/mbgl/style/parser.cpp
@@ -119,6 +119,9 @@ StyleParseResult Parser::parse(const std::string& json) {
}
}
+ // Call for side effect of logging warnings for invalid values.
+ fontStacks();
+
return nullptr;
}
@@ -286,6 +289,9 @@ std::vector<FontStack> Parser::fontStacks() const {
for (const auto& value : function.possibleOutputs()) {
if (value) {
result.insert(*value);
+ } else {
+ Log::Warning(Event::ParseStyle, "Layer '%s' has an invalid value for text-font and will not work offline. Output values must be contained as literals within the expression.", layer->getID().c_str());
+ break;
}
}
}