Browse Source

FileServer.st: log to console if file not found

mkroehnert 12 năm trước cách đây
mục cha
commit
6971427d58
1 tập tin đã thay đổi với 3 bổ sung1 xóa
  1. 3 1
      server/FileServer.st

+ 3 - 1
server/FileServer.st

@@ -98,7 +98,9 @@ respondFileNamed: aFilename to: aResponse
 
 	fs readFile: filename do: [:ex :file |
 		ex notNil 
-			ifTrue: [self respondInternalErrorTo: aResponse]
+			ifTrue: [
+				console log: filename, ' does not exist'.
+				self respondInternalErrorTo: aResponse]
 			ifFalse: [
 				type := self class mimeTypeFor: filename.
 				type = 'application/javascript'