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

Rename *RefreshKind::new method into nothing #1402

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

GuillaumeGomez
Copy link
Owner

@GuillaumeGomez GuillaumeGomez commented Nov 28, 2024

Fixes #1400.

So now, instead of writing DiskRefreshKind::new() if you don't want to refresh disks information, you will write DiskRefreshKind::nothing().

@softdevca
Copy link
Contributor

I agree with renaming::new() to ::nothing()`. It makes it more clear what will be refreshed.

@afiqzx
Copy link

afiqzx commented Nov 29, 2024

Would ::new_nothing() be better?

Edit: after looking thoroughly the changes, I agree changing it to nothing()

Copy link

@alice-i-cecile alice-i-cecile left a comment

Choose a reason for hiding this comment

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

How about do_not_refresh?

@Hywan
Copy link

Hywan commented Nov 29, 2024

Here is another feedback: what about *RefreshKind::none()?

@algesten
Copy link

algesten commented Nov 29, 2024

Here is another feedback: what about *RefreshKind::none()?

English is not my first language but spontaneously I had the same thought. A kind feels like it must be paired with none.

@GuillaumeGomez
Copy link
Owner Author

@Hywan, @algesten: The "equivalent" method is everything(). I'm not sure whether nothing or none is a better match. With this in mind, do you still think the same?

@GuillaumeGomez
Copy link
Owner Author

How about do_not_refresh?

Sounds a bit weird no? It would look like this: RefreshKind::do_not_refresh.

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.

Rename Refresh*Kind::new method into nothing
6 participants