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

Support empty maps #127

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Support empty maps #127

wants to merge 2 commits into from

Conversation

nibe
Copy link

@nibe nibe commented Jan 22, 2020

Before:

(loom.graph/graph {})
Execution error (NullPointerException) at loom.graph/build-graph$build (graph.cljc:499).
null

After:

(loom.graph/graph {})
=> #loom.graph.BasicEditableGraph{:nodeset #{}, :adj {}}

Of course you could call (loom.graph/graph) instead but the point is to remove a pitfall when dealing with maps.

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.

1 participant