Fix golint error
golint has figured out an optimization that is blocking other pull requests. This fixes the golint issue. Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
This commit is contained in:
parent
fdc7f5a77a
commit
bf6c4141c1
1 changed files with 2 additions and 4 deletions
|
@ -69,11 +69,9 @@ func RunUnderSystemdScope(pid int, slice string, unitName string) error {
|
||||||
properties = append(properties, newProp("PIDs", []uint32{uint32(pid)}))
|
properties = append(properties, newProp("PIDs", []uint32{uint32(pid)}))
|
||||||
properties = append(properties, newProp("Delegate", true))
|
properties = append(properties, newProp("Delegate", true))
|
||||||
properties = append(properties, newProp("DefaultDependencies", false))
|
properties = append(properties, newProp("DefaultDependencies", false))
|
||||||
if _, err := conn.StartTransientUnit(unitName, "replace", properties, nil); err != nil {
|
_, err = conn.StartTransientUnit(unitName, "replace", properties, nil)
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
return nil
|
|
||||||
}
|
|
||||||
|
|
||||||
func newProp(name string, units interface{}) systemdDbus.Property {
|
func newProp(name string, units interface{}) systemdDbus.Property {
|
||||||
return systemdDbus.Property{
|
return systemdDbus.Property{
|
||||||
|
|
Loading…
Reference in a new issue