summaryrefslogtreecommitdiffstats
path: root/Lib/ftplib.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/ftplib.py')
-rw-r--r--Lib/ftplib.py4
1 files changed, 1 insertions, 3 deletions
diff --git a/Lib/ftplib.py b/Lib/ftplib.py
index 42f2bff..7e678b4 100644
--- a/Lib/ftplib.py
+++ b/Lib/ftplib.py
@@ -223,7 +223,7 @@ class FTP:
def voidresp(self):
"""Expect a response beginning with '2'."""
resp = self.getresp()
- if resp[0] != '2':
+ if resp[:1] != '2':
raise error_reply(resp)
return resp
@@ -522,8 +522,6 @@ class FTP:
resp = self.sendcmd('DELE ' + filename)
if resp[:3] in ('250', '200'):
return resp
- elif resp[:1] == '5':
- raise error_perm(resp)
else:
raise error_reply(resp)