Add customization_weight parameter to recognize() for stt#309
Merged
ammardodin merged 3 commits intomasterfrom Nov 27, 2017
Merged
Add customization_weight parameter to recognize() for stt#309ammardodin merged 3 commits intomasterfrom
ammardodin merged 3 commits intomasterfrom
Conversation
Codecov Report
@@ Coverage Diff @@
## master #309 +/- ##
==========================================
+ Coverage 38.72% 38.75% +0.02%
==========================================
Files 24 24
Lines 8292 8294 +2
==========================================
+ Hits 3211 3214 +3
+ Misses 5081 5080 -1
Continue to review full report at Codecov.
|
mkistler
suggested changes
Nov 26, 2017
| if (params['customization_id'] is not None and | ||
| customization_weight is not None): | ||
| params['customization_weight'] = customization_weight | ||
|
|
There was a problem hiding this comment.
I think you can simply add
'customization_weight': customization_weight,
into the params object above. The check for customization_weight is not None isn't needed because the service will strip it out, and the check for 'customization_id' shouldn't be needed because the service should simply ignore it when there is no customization_id.
Contributor
Author
There was a problem hiding this comment.
Ah, touche. I see you're removing None values in the base service. Nice !! 👍
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #306