Skip to content

Commit 3281576

Browse files
committed
Import cleanup
1 parent f999dc6 commit 3281576

2 files changed

Lines changed: 2 additions & 4 deletions

File tree

src/HTTPServer.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@
1818

1919
#include "HTTPServer.h"
2020

21-
#include <unordered_map>
2221
#include <vector>
2322
#include <string>
2423
#include <ctime>
@@ -689,7 +688,7 @@ ResourceHost* HTTPServer::getResourceHostForRequest(const HTTPRequest* req) {
689688
host.append(std::format(":{}", listenPort));
690689
}
691690

692-
std::unordered_map<std::string, ResourceHost*>::const_iterator it = vhosts.find(host);
691+
auto it = vhosts.find(host);
693692

694693
if (it != vhosts.end())
695694
resHost = it->second;

src/ResourceHost.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@
2020

2121
#include <sstream>
2222
#include <string>
23-
#include <unordered_map>
2423
#include <fstream>
2524
#include <dirent.h>
2625
#include <sys/stat.h>
@@ -37,7 +36,7 @@ ResourceHost::ResourceHost(std::string const& base) : baseDiskPath(base) {
3736
* @return MIME type as a String. If type could not be found, returns an empty string
3837
*/
3938
std::string ResourceHost::lookupMimeType(std::string const& ext) {
40-
std::unordered_map<std::string, std::string>::const_iterator it = mimeMap.find(ext);
39+
auto it = mimeMap.find(ext);
4140
if (it == mimeMap.end())
4241
return "";
4342

0 commit comments

Comments
 (0)