| 29 | } |
| 30 | |
| 31 | void onFile(HttpRequest& request, HttpResponse& response) |
| 32 | { |
| 33 | String file = request.uri.getRelativePath(); |
| 34 | |
| 35 | if(file[0] == '.') { |
| 36 | response.code = HTTP_STATUS_FORBIDDEN; |
| 37 | } else { |
| 38 | response.setCache(86400, true); // It's important to use cache for better performance. |
| 39 | response.sendFile(file); |
| 40 | } |
| 41 | } |
| 42 | |
| 43 | void shutdownServer() |
| 44 | { |
nothing calls this directly
no test coverage detected