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

Float-friendly replacement for Django's built-in add filter. #10

Merged
merged 2 commits into from
May 26, 2015

Conversation

centricle
Copy link

Float-friendly replacement for Django's built-in add filter.

@coveralls
Copy link

Coverage Status

Coverage decreased (-1.49%) to 62.37% when pulling 537d5d6 on centricle:master into 4901e8d on dbrgn:master.

@dbrgn
Copy link
Owner

dbrgn commented May 24, 2015

Thanks! Calling it sum solves the add conflict :)



@register.filter(name='sum')
def sum(value, arg):
Copy link
Owner

Choose a reason for hiding this comment

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

Maybe call the function addition to avoid overloading Python's sum builtin?

@dbrgn
Copy link
Owner

dbrgn commented May 24, 2015

Also, maybe add 2-3 tests involving Decimal (see other tests) to avoid decreasing the test coverage?

@dbrgn dbrgn mentioned this pull request May 24, 2015
@coveralls
Copy link

Coverage Status

Coverage decreased (-1.49%) to 62.37% when pulling 07e4562 on centricle:master into 4901e8d on dbrgn:master.

@centricle
Copy link
Author

Huh. Coveralls is complaining about existing tests that weren't touched. I wonder if something changed on their end.

@dbrgn
Copy link
Owner

dbrgn commented May 26, 2015

Huh, strange. Anyways, your PR looks good. Thanks!

dbrgn added a commit that referenced this pull request May 26, 2015
Float-friendly replacement for Django's built-in `add` filter.
@dbrgn dbrgn merged commit f1c15de into dbrgn:master May 26, 2015
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

3 participants