mirror of
				https://source.quilibrium.com/quilibrium/ceremonyclient.git
				synced 2025-11-04 00:57:26 +00:00 
			
		
		
		
	
		
			
				
	
	
		
			24 lines
		
	
	
		
			373 B
		
	
	
	
		
			Go
		
	
	
	
	
	
			
		
		
	
	
			24 lines
		
	
	
		
			373 B
		
	
	
	
		
			Go
		
	
	
	
	
	
package autorelay
 | 
						|
 | 
						|
import (
 | 
						|
	"github.com/libp2p/go-libp2p/core/host"
 | 
						|
)
 | 
						|
 | 
						|
type AutoRelayHost struct {
 | 
						|
	host.Host
 | 
						|
	ar *AutoRelay
 | 
						|
}
 | 
						|
 | 
						|
func (h *AutoRelayHost) Close() error {
 | 
						|
	_ = h.ar.Close()
 | 
						|
	return h.Host.Close()
 | 
						|
}
 | 
						|
 | 
						|
func (h *AutoRelayHost) Start() {
 | 
						|
	h.ar.Start()
 | 
						|
}
 | 
						|
 | 
						|
func NewAutoRelayHost(h host.Host, ar *AutoRelay) *AutoRelayHost {
 | 
						|
	return &AutoRelayHost{Host: h, ar: ar}
 | 
						|
}
 |