From 1d49c23b8558e8c24a51e7ba84525ddd06f231be Mon Sep 17 00:00:00 2001 From: zmiao Date: Tue, 5 Nov 2019 13:41:46 +0200 Subject: [render-test] Fix render-test manifest confilicted local and member names (#15888) --- render-test/manifest_parser.cpp | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'render-test') diff --git a/render-test/manifest_parser.cpp b/render-test/manifest_parser.cpp index 3e56138e83..3f1f9f3866 100644 --- a/render-test/manifest_parser.cpp +++ b/render-test/manifest_parser.cpp @@ -46,8 +46,8 @@ void Manifest::doShuffle(uint32_t seed) { std::string Manifest::localizeURL(const std::string& url) const { static const std::regex regex{"local://"}; - if (auto vendorPath = getVendorPath(url, regex)) { - return *vendorPath; + if (auto path = getVendorPath(url, regex)) { + return *path; } return getIntegrationPath(url, "", regex).value_or(url); } @@ -131,16 +131,16 @@ void Manifest::localizeStyleURLs(mbgl::JSValue& root, mbgl::JSDocument& document mbgl::optional Manifest::localizeLocalURL(const std::string& url, bool glyphsPath) const { static const std::regex regex{"local://"}; - if (auto vendorPath = getVendorPath(url, regex, glyphsPath)) { - return vendorPath; + if (auto path = getVendorPath(url, regex, glyphsPath)) { + return path; } return getIntegrationPath(url, "", regex, glyphsPath); } mbgl::optional Manifest::localizeHttpURL(const std::string& url) const { static const std::regex regex{"http://localhost:2900"}; - if (auto vendorPath = getVendorPath(url, regex)) { - return vendorPath; + if (auto path = getVendorPath(url, regex)) { + return path; } return getIntegrationPath(url, "", regex); } @@ -157,8 +157,8 @@ mbgl::optional Manifest::localizeMapboxFontsURL(const std::string& mbgl::optional Manifest::localizeMapboxTilesURL(const std::string& url) const { static const std::regex regex{"mapbox://"}; - if (auto vendorPath = getVendorPath(url, regex)) { - return vendorPath; + if (auto path = getVendorPath(url, regex)) { + return path; } return getIntegrationPath(url, "tiles/", regex); } -- cgit v1.2.1