{"action":"created","issue":{"url":"https://api.github.com/repos/mapbox/mapbox-gl-native/issues/739","labels_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/issues/739/labels{/name}","comments_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/issues/739/comments","events_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/issues/739/events","html_url":"https://github.com/mapbox/mapbox-gl-native/issues/739","id":53351210,"number":739,"title":"Map::getAppliedStyleClasses crashes if called before style finishes loading","user":{"login":"ljbade","id":1215089,"avatar_url":"https://avatars.githubusercontent.com/u/1215089?v=3","gravatar_id":"","url":"https://api.github.com/users/ljbade","html_url":"https://github.com/ljbade","followers_url":"https://api.github.com/users/ljbade/followers","following_url":"https://api.github.com/users/ljbade/following{/other_user}","gists_url":"https://api.github.com/users/ljbade/gists{/gist_id}","starred_url":"https://api.github.com/users/ljbade/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ljbade/subscriptions","organizations_url":"https://api.github.com/users/ljbade/orgs","repos_url":"https://api.github.com/users/ljbade/repos","events_url":"https://api.github.com/users/ljbade/events{/privacy}","received_events_url":"https://api.github.com/users/ljbade/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-01-04T22:31:28Z","updated_at":"2015-01-04T22:33:10Z","closed_at":null,"body":"I have encountered a crash if Map::getAppliedStyleClasses is called before the style finishes loading.\r\n\r\nThe only way around this is to either change getAppliedStyleClasses to return a pointer so null means the style hasn't loaded or to add a new function that returns a status to indicate the style has finished loading."},"comment":{"url":"https://api.github.com/repos/mapbox/mapbox-gl-native/issues/comments/68652604","html_url":"https://github.com/mapbox/mapbox-gl-native/issues/739#issuecomment-68652604","issue_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/issues/739","id":68652604,"user":{"login":"ljbade","id":1215089,"avatar_url":"https://avatars.githubusercontent.com/u/1215089?v=3","gravatar_id":"","url":"https://api.github.com/users/ljbade","html_url":"https://github.com/ljbade","followers_url":"https://api.github.com/users/ljbade/followers","following_url":"https://api.github.com/users/ljbade/following{/other_user}","gists_url":"https://api.github.com/users/ljbade/gists{/gist_id}","starred_url":"https://api.github.com/users/ljbade/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ljbade/subscriptions","organizations_url":"https://api.github.com/users/ljbade/orgs","repos_url":"https://api.github.com/users/ljbade/repos","events_url":"https://api.github.com/users/ljbade/events{/privacy}","received_events_url":"https://api.github.com/users/ljbade/received_events","type":"User","site_admin":false},"created_at":"2015-01-04T22:33:10Z","updated_at":"2015-01-04T22:33:10Z","body":"We should also add an assert(style) to all functions that should not be called until the style has loaded."}}