diff options
Diffstat (limited to 'src/mbgl/map/map_context.cpp')
-rw-r--r-- | src/mbgl/map/map_context.cpp | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/src/mbgl/map/map_context.cpp b/src/mbgl/map/map_context.cpp index 03da5ee321..6b4657f0af 100644 --- a/src/mbgl/map/map_context.cpp +++ b/src/mbgl/map/map_context.cpp @@ -113,14 +113,11 @@ void MapContext::setStyleURL(const std::string& url) { Log::Error(Event::Setup, "loading style failed: %s", res.error->message.c_str()); data.loading = false; } + } else if (res.notModified || res.noContent) { return; + } else { + loadStyleJSON(*res.data, base); } - - if (res.notModified) { - return; - } - - loadStyleJSON(*res.data, base); }); } |