Skip to content

Commit b106d2d

Browse files
committed
web-server: fix "'ERR_NO_PERM' is not defined"
1 parent 039f458 commit b106d2d

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

web-server/04-errcode-pathnorm/server.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ def handle_dir(self, abs_path):
103103
self.send_content(content)
104104
except IOError, msg:
105105
msg = "'%s' cannot be listed: %s" % (self.path, msg)
106-
self.send_error(ERR_NO_PERM, msg)
106+
self.send_error(self.ERR_NO_PERM, msg)
107107

108108
# Send actual content.
109109
def send_content(self, content):

web-server/chapter.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -347,7 +347,7 @@ included in the HTTP request.
347347
(We'll do this pretty frequently when debugging,
348348
so we might as well get some practice.)
349349
To keep our code clean,
350-
we'l separate creating the page from sending it:
350+
we'll separate creating the page from sending it:
351351

352352
~~~ {file="01-echo-request-info/server.py"}
353353
class RequestHandler(BaseHTTPServer.BaseHTTPRequestHandler):

0 commit comments

Comments
 (0)