mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-23 01:21:42 +00:00
Include .h from .inc/.inl files (NFC) (#3017)
This helps both IDEs and linting tools. Also add some missing braces.
This commit is contained in:
@@ -7,6 +7,8 @@
|
||||
|
||||
#include <utility>
|
||||
|
||||
#include "wpi/HttpUtil.h"
|
||||
|
||||
namespace wpi {
|
||||
|
||||
inline HttpPathRef HttpPath::drop_front(size_t n) const {
|
||||
@@ -17,10 +19,12 @@ template <typename T>
|
||||
HttpRequest::HttpRequest(const HttpLocation& loc, const T& extraParams)
|
||||
: host{loc.host}, port{loc.port} {
|
||||
StringMap<StringRef> params;
|
||||
for (const auto& p : loc.params)
|
||||
for (const auto& p : loc.params) {
|
||||
params.insert(std::make_pair(GetFirst(p), GetSecond(p)));
|
||||
for (const auto& p : extraParams)
|
||||
}
|
||||
for (const auto& p : extraParams) {
|
||||
params.insert(std::make_pair(GetFirst(p), GetSecond(p)));
|
||||
}
|
||||
SetPath(loc.path, params);
|
||||
SetAuth(loc);
|
||||
}
|
||||
|
||||
@@ -7,6 +7,8 @@
|
||||
|
||||
#include <memory>
|
||||
|
||||
#include "wpi/HttpWebSocketServerConnection.h"
|
||||
|
||||
namespace wpi {
|
||||
|
||||
template <typename Derived>
|
||||
@@ -22,8 +24,9 @@ HttpWebSocketServerConnection<Derived>::HttpWebSocketServerConnection(
|
||||
StringRef protocol = m_helper.MatchProtocol(protocols).second;
|
||||
|
||||
// Check that the upgrade is valid
|
||||
if (!IsValidWsUpgrade(protocol))
|
||||
if (!IsValidWsUpgrade(protocol)) {
|
||||
return;
|
||||
}
|
||||
|
||||
// Disconnect HttpServerConnection header reader
|
||||
m_dataConn.disconnect();
|
||||
|
||||
@@ -6,6 +6,8 @@
|
||||
|
||||
#include <algorithm>
|
||||
|
||||
#include "wpi/circular_buffer.h"
|
||||
|
||||
namespace wpi {
|
||||
|
||||
template <class T>
|
||||
|
||||
Reference in New Issue
Block a user