| 30 | } |
| 31 | |
| 32 | bool FtpServer::onCommand(String cmd, [[maybe_unused]] String data, FtpServerConnection& connection) |
| 33 | { |
| 34 | if(cmd == _F("FSFORMAT")) { |
| 35 | auto fs = connection.getFileSystem(); |
| 36 | if(fs != nullptr) { |
| 37 | int err = fs->format(); |
| 38 | connection.response(200, F("File system format: ") + fileGetErrorString(err)); |
| 39 | } |
| 40 | return true; |
| 41 | } |
| 42 | return false; |
| 43 | } |
nothing calls this directly
no test coverage detected