Rename and refactor overlay constructor functions
- Reduces redundancy - Adds clarity Signed-off-by: Jonathon Anderson <janderson@ciq.com>
This commit is contained in:
committed by
Christian Goll
parent
717241aa18
commit
ac49ecef70
@@ -21,11 +21,11 @@ func CobraRunE(cmd *cobra.Command, args []string) error {
|
||||
if err != nil {
|
||||
return fmt.Errorf("could not convert requested mode: %s", err)
|
||||
}
|
||||
err = overlay.CreateSiteOverlay(overlayName)
|
||||
err = overlay.CloneSiteOverlay(overlayName)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
overlaySourceDir, _ = overlay.OverlaySourceDir(overlayName)
|
||||
overlaySourceDir, _ = overlay.GetOverlay(overlayName)
|
||||
|
||||
if !util.IsDir(overlaySourceDir) {
|
||||
return fmt.Errorf("overlay does not exist: %s", overlayName)
|
||||
|
||||
Reference in New Issue
Block a user