[core] Don't use exceptions in MapObserver::onDidFailLoadingMap
Using different exception pointers to specify the loading failure makes an awkward API. Most users rethrow the exception only to figure out what type of error happened so it can be reported properly. So replace the exception pointer with a enum an string description of the failure.
This commit is contained in:
@@ -22,7 +22,7 @@ class HeadlessFrontend;
|
||||
namespace node_mbgl {
|
||||
|
||||
class NodeMapObserver : public mbgl::MapObserver {
|
||||
void onDidFailLoadingMap(std::exception_ptr) override;
|
||||
void onDidFailLoadingMap(mbgl::MapLoadError, const std::string&) override;
|
||||
};
|
||||
|
||||
class NodeMap;
|
||||
|
||||
Reference in New Issue
Block a user