mirror of
https://github.com/edera-dev/sprout.git
synced 2025-12-19 15:20:17 +00:00
fix(bls): quirk for when the version field is present already in the title
This commit is contained in:
@@ -186,8 +186,9 @@ pub fn generate(context: Rc<SproutContext>, bls: &BlsConfiguration) -> Result<Ve
|
||||
// Put the initrd through a quirk modifier to support Fedora.
|
||||
let initrd = quirk_initrd_remove_tuned(entry.initrd_path().unwrap_or_default());
|
||||
|
||||
// Combine the title with the version if a version is present.
|
||||
let title_full = if !version.is_empty() {
|
||||
// Combine the title with the version if a version is present, except if it already contains it.
|
||||
// Sometimes BLS will have a version in the title already, and this makes it unique.
|
||||
let title_full = if !version.is_empty() && !title_base.contains(&version) {
|
||||
format!("{} {}", title_base, version)
|
||||
} else {
|
||||
title_base.clone()
|
||||
|
||||
Reference in New Issue
Block a user