diff --git a/ltm.go b/ltm.go index 2c3ddc7..d95ffd8 100644 --- a/ltm.go +++ b/ltm.go @@ -1036,11 +1036,12 @@ func (b *BigIP) ModifyMonitor(name, parent string, config *Monitor) error { // AddMonitorToPool assigns the monitor, to the given . func (b *BigIP) AddMonitorToPool(monitor, pool string) error { - config := &Pool{ - Monitor: monitor, + p, err := b.GetPool(pool) + if err != nil { + return err } - - return b.put(config, uriLtm, uriPool, pool) + p.Monitor = monitor + return b.ModifyPool(pool, p) } // IRules returns a list of irules