mirror of
https://github.com/arnaucube/go-ethereum.git
synced 2026-02-28 05:56:45 +01:00
internal/build: fix usage of strings.TrimLeft (#16066)
This commit is contained in:
committed by
Péter Szilágyi
parent
4065695350
commit
52ad848b2e
@@ -94,7 +94,7 @@ func LocalEnv() Environment {
|
||||
}
|
||||
if env.Branch == "" {
|
||||
if head != "HEAD" {
|
||||
env.Branch = strings.TrimLeft(head, "refs/heads/")
|
||||
env.Branch = strings.TrimPrefix(head, "refs/heads/")
|
||||
}
|
||||
}
|
||||
if info, err := os.Stat(".git/objects"); err == nil && info.IsDir() && env.Tag == "" {
|
||||
|
||||
Reference in New Issue
Block a user