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

1.0.8/render block container as block for any non addresses #60

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

Conversation

mzagrabe
Copy link
Contributor

When a container has a mix of addresses (hosts) and other subnets or containers it should display the block view if any of its descendants are non-addresses.

Don't just evaluate the first object of the array - this leads to issues
where a container has static addresses at the top of the addressing
block (first entry of the array) and the whole block is rendered as though
they were hosts (addresses).

Instead, default to 'address' and see if any of the objects are not
addresses. If so, then set the type to 'block' and break the loop.
Regex anchors bind tighter than the alternation character (|). Thus we
need to put our alternation expression in a (non-capturing) parenthesis.
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