Skip to content

Improve get_efi_vendor() to use Path - #997

Merged
HuijingHei merged 1 commit into
coreos:mainfrom
HuijingHei:improve-step2-prep
Sep 5, 2025
Merged

HuijingHei merged 1 commit into
coreos:mainfrom
HuijingHei:improve-step2-prep

Conversation

@HuijingHei

Copy link
Copy Markdown
Contributor

This follows #991 (comment)

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Code Review

This pull request is a nice improvement, refactoring get_efi_vendor to use &Path instead of &str for path arguments. This is a good practice in Rust that improves type safety and code clarity. The changes are applied consistently across the trait definition, implementations, and call sites. The test cases are also updated accordingly.

I have one suggestion in src/efi.rs to make the implementation slightly more efficient by avoiding some unnecessary memory allocations. Overall, this is a solid refactoring.

Comment thread src/efi.rs Outdated
@HuijingHei
HuijingHei force-pushed the improve-step2-prep branch 2 times, most recently from 254a6e3 to e5247b2 Compare September 4, 2025 08:16

@PeaceRebel PeaceRebel left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

LGTM. Not tested.

@HuijingHei
HuijingHei merged commit 36d7b43 into coreos:main Sep 5, 2025
12 checks passed
@HuijingHei
HuijingHei deleted the improve-step2-prep branch September 5, 2025 13:13
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.

3 participants