Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Warn on trying to create an unsupported feature. #823

Merged
merged 2 commits into from
May 25, 2018

Conversation

manthey
Copy link
Contributor

@manthey manthey commented May 23, 2018

When a feature is requested that a layer doesn't support, issue a warning. Don't fail in the geojson reader when this occurs.

When a feature is requested that a layer doesn't support, issue a
warning.  Don't fail in the geojson reader when this occurs.
Copy link
Member

@aashish24 aashish24 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM with one minor suggestion on line length

@@ -45,6 +45,8 @@ var featureLayer = function (arg) {
featureName, m_this, m_this.renderer(), arg);
if (newFeature) {
this.addFeature(newFeature);
} else {
console.warn('Layer renderer (' + m_this.rendererName() + ') does not support feature type "' + featureName + '"');
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

perhaps the line is little too long (I cannot read end-to-end on my browser) but other than that it looks good.

@manthey manthey merged commit 8ca5b61 into master May 25, 2018
@manthey manthey deleted the improve-feature-warnings branch May 25, 2018 16:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants