Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def __init__(self, name, listener, poller, ip_address, port, action_handler = None):
self.serial = self.make_uuid(name)
self.name = name
self.ip_address = ip_address
persistent_uuid = "Socket-1_0-" + self.serial
other_headers = ['X-User-Agent: redsonic']
upnp_device.__init__(self, listener, poller, port, "http://%(ip_address)s:%(port)s/setup.xml", "Unspecified, UPnP/1.0, Unspecified", persistent_uuid, other_headers=other_headers, ip_address=ip_address)
if action_handler:
self.action_handler = action_handler
else:
self.action_handler = self
dbg("FauxMo device '%s' ready on %s:%s" % (self.name, self.ip_address, self.port))
def __init__(self, name, listener, poller, ip_address, port, action_handler = None, log = None):
self.serial = self.make_uuid(name)
self.name = name
self.switchStatus=0
self.ip_address = ip_address
if (log != None):
self.log = log
persistent_uuid = "Socket-1_0-" + self.serial
other_headers = ['X-User-Agent: redsonic']
upnp_device.__init__(self, listener, poller, port, "http://%(ip_address)s:%(port)s/setup.xml", "Unspecified, UPnP/1.0, Unspecified", persistent_uuid, other_headers=other_headers, ip_address=ip_address, log=self.log)
if action_handler:
self.action_handler = action_handler
else:
self.action_handler = self
self.LogInfo("FauxMo device '%s' ready on %s:%s" % (self.name, self.ip_address, self.port))
def __init__(self, name, listener, poller, ip_address, port, action_handler = None):
self.serial = self.make_uuid(name)
self.name = name
self.switchStatus=0
self.ip_address = ip_address
persistent_uuid = "Socket-1_0-" + self.serial
other_headers = ['X-User-Agent: redsonic']
upnp_device.__init__(self, listener, poller, port, "http://%(ip_address)s:%(port)s/setup.xml", "Unspecified, UPnP/1.0, Unspecified", persistent_uuid, other_headers=other_headers, ip_address=ip_address)
if action_handler:
self.action_handler = action_handler
else:
self.action_handler = self
dbg("FauxMo device '%s' ready on %s:%s" % (self.name, self.ip_address, self.port))