Change func name from return_squares to get_squares
This commit is contained in:
parent
487f7cc0d7
commit
7c97c94ba5
@ -21,12 +21,12 @@ class SimpleHandler(server.BaseHTTPRequestHandler):
|
|||||||
elif path == "/yang":
|
elif path == "/yang":
|
||||||
msg = self.return_yang()
|
msg = self.return_yang()
|
||||||
elif path == "/squares":
|
elif path == "/squares":
|
||||||
msg = self.return_squares(query_components)
|
msg = self.get_squares(query_components)
|
||||||
else:
|
else:
|
||||||
msg = "Error 404"
|
msg = "Error 404"
|
||||||
self.wfile.write(msg.encode('utf-8'))
|
self.wfile.write(msg.encode('utf-8'))
|
||||||
|
|
||||||
def return_squares(self, query_components):
|
def get_squares(self, query_components):
|
||||||
if len(query_components) != 2:
|
if len(query_components) != 2:
|
||||||
msg = "Invalid number of Query Components! Two components needed."
|
msg = "Invalid number of Query Components! Two components needed."
|
||||||
else:
|
else:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user