Skip to content

Commit

Permalink
can avoid making name public since we have a getter
Browse files Browse the repository at this point in the history
Signed-off-by: clux <sszynrae@gmail.com>
  • Loading branch information
clux committed May 23, 2022
1 parent bcaf4f0 commit 2888608
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion kube-client/src/discovery/apigroup.rs
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ use std::cmp::Reverse;
/// [`ApiGroup::recommended_kind`]: crate::discovery::ApiGroup::recommended_kind
pub struct ApiGroup {
/// Name of the group e.g. apiregistration.k8s.io
pub name: String,
name: String,
/// List of resource information, capabilities at particular versions
data: Vec<GroupVersionData>,
/// Preferred version if exported by the `APIGroup`
Expand Down
2 changes: 1 addition & 1 deletion kube-client/src/discovery/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ impl Discovery {
pub fn groups_alphabetical(&self) -> Vec<&ApiGroup> {
let mut values: Vec<_> = self.groups().collect();
// collect to maintain kubectl order of groups
values.sort_by_key(|g| &g.name);
values.sort_by_key(|g| g.name());
values
}

Expand Down

0 comments on commit 2888608

Please sign in to comment.