Skip to content
Snippets Groups Projects
Commit 500a36f3 authored by Rob Swindell's avatar Rob Swindell :speech_balloon:
Browse files

Store last received response in 'received_response' property

For Nelgin's use in exception handler of something that's using this script
parent f4cff314
No related branches found
No related tags found
No related merge requests found
...@@ -352,6 +352,7 @@ FTP.prototype.cmd = function(cmd, needresp) ...@@ -352,6 +352,7 @@ FTP.prototype.cmd = function(cmd, needresp)
do { do {
rd = this.socket.recvline(this.maxline, this.timeout - (time() - start)); rd = this.socket.recvline(this.maxline, this.timeout - (time() - start));
if (rd !== null) { if (rd !== null) {
this.received_response = rd;
m = rd.match(/^([0-9]{3})([- ])/); m = rd.match(/^([0-9]{3})([- ])/);
if (rsp === undefined) { if (rsp === undefined) {
if (m === null) { if (m === null) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment