Skip to content

Refactor query/analytics/search params/raw to remove value from API#226

Merged
chvck merged 1 commit intonativexfrom
params
Jan 16, 2025
Merged

Refactor query/analytics/search params/raw to remove value from API#226
chvck merged 1 commit intonativexfrom
params

Conversation

@chvck
Copy link
Collaborator

@chvck chvck commented Jan 16, 2025

No description provided.

Copy link

@Westwooo Westwooo left a comment

Choose a reason for hiding this comment

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

LGTM, just one nit

) -> error::Result<Self> {
let value = serde_json::to_value(&value)?;

match self.named_parameters {

Choose a reason for hiding this comment

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

nit: could do:

if let Some(mut params) = self.named_params {
...
} else {
...
}

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Interestingly clippy isn't highlighting that as a recommendation

let parameters = serde_json::to_value(&parameters)?;

match self.positional_parameters {
Some(mut params) => {

Choose a reason for hiding this comment

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

Same nit here and in add_raw.

@chvck chvck merged commit a5747e3 into nativex Jan 16, 2025
15 of 17 checks passed
@chvck chvck deleted the params branch January 16, 2025 12:03
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.

2 participants