Skip unnecessary repeititon in validation
Test: Unit tests Change-Id: I492d3157b1dee358871924071b26a73e8b83a9a5
This commit is contained in:
committed by
Christopher Parsons
parent
295ae69b04
commit
a66c0b5900
@@ -2389,8 +2389,7 @@ func (b *baseModuleContext) ModuleFromName(name string) (blueprint.Module, bool)
|
|||||||
if !b.BazelConversionMode() {
|
if !b.BazelConversionMode() {
|
||||||
panic("cannot call ModuleFromName if not in bazel conversion mode")
|
panic("cannot call ModuleFromName if not in bazel conversion mode")
|
||||||
}
|
}
|
||||||
if len(name) > 1 && (name[0] == ':' || (name[0] == '/' && name[1] == '/')) {
|
if moduleName, _ := SrcIsModuleWithTag(name); moduleName != "" {
|
||||||
moduleName, _ := SrcIsModuleWithTag(name)
|
|
||||||
return b.bp.ModuleFromName(moduleName)
|
return b.bp.ModuleFromName(moduleName)
|
||||||
} else {
|
} else {
|
||||||
return b.bp.ModuleFromName(name)
|
return b.bp.ModuleFromName(name)
|
||||||
|
Reference in New Issue
Block a user