.format
This commit is contained in:
parent
a211115b7e
commit
2812569593
1 changed files with 3 additions and 4 deletions
|
@ -50,8 +50,7 @@ def mcping_connect(host, port):
|
||||||
return message
|
return message
|
||||||
|
|
||||||
except:
|
except:
|
||||||
return "Error pinging " + host + ":" + str(port) + \
|
return "Error pinging {}:{}, is it up? Double-check your address!".format(host,str(port))
|
||||||
", is it up? Double-check your address!"
|
|
||||||
|
|
||||||
|
|
||||||
def srvData(domain):
|
def srvData(domain):
|
||||||
|
@ -91,8 +90,8 @@ def mcping(inp):
|
||||||
port = int(getdata[0])
|
port = int(getdata[0])
|
||||||
return format_motd(mcping_connect(host, port))
|
return format_motd(mcping_connect(host, port))
|
||||||
except:
|
except:
|
||||||
return "Error pinging %s, is it up? Double-check your address!" % inp
|
return "Error pinging {}, is it up? Double-check your address!".format(inp)
|
||||||
else:
|
else:
|
||||||
return "Error pinging %s, is it up? Double-check your address!" % inp
|
return "Error pinging {}, is it up? Double-check your address!".format(inp)
|
||||||
else:
|
else:
|
||||||
return rdata
|
return rdata
|
||||||
|
|
Reference in a new issue