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

Fix exception that occurred when tags parameter is not supplied to add_items() #69

Merged
merged 2 commits into from
Jan 13, 2019

Conversation

ScottKinSF
Copy link
Contributor

@ScottKinSF ScottKinSF commented Jan 12, 2019

Changed default value of tags from None (not iterable) to list() (iterable).

- changed default value of tags from None to list()
@5iver
Copy link
Member

5iver commented Jan 12, 2019

Excellent! To keep things consistent with the rest of the code, could you switch it to [] instead of list()? Or is it better to use list()?

@ScottKinSF
Copy link
Contributor Author

Sure thing. I honestly don't know which way of specifying an empty list is preferred in the python world, I'm more of a C++ guy.

@5iver
Copy link
Member

5iver commented Jan 13, 2019

[] is faster! 😄 https://stackoverflow.com/a/2972226

@5iver 5iver merged commit c5adc9b into openhab-scripters:master Jan 13, 2019
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.

None yet

2 participants