summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authortastytea2020-01-08 17:38:27 +0100
committertastytea2020-01-08 17:38:27 +0100
commit4b118e75f13c15d8ab197ea5c2314b06956f2e76 (patch)
tree3d6e72ade4c33c492b47d434c20696c3d52060e2
parent577c252b4232af466a6c186b5fa5fc79e999747c (diff)
downloadmastodonpp-4b118e75f13c15d8ab197ea5c2314b06956f2e76.tar
mastodonpp-4b118e75f13c15d8ab197ea5c2314b06956f2e76.tar.gz
mastodonpp-4b118e75f13c15d8ab197ea5c2314b06956f2e76.zip
Fix / ignore some clang-tidy warnings.
-rw-r--r--include/connection.hpp2
-rw-r--r--include/curl_wrapper.hpp2
-rw-r--r--include/instance.hpp3
-rw-r--r--src/api.cpp2
4 files changed, 5 insertions, 4 deletions
diff --git a/include/connection.hpp b/include/connection.hpp
index 09a3945..5ffe969 100644
--- a/include/connection.hpp
+++ b/include/connection.hpp
@@ -104,7 +104,7 @@ public:
* Sets also the proxy for the Instance you used to initialize this
* Connection.
*/
- void set_proxy(const string_view proxy);
+ void set_proxy(string_view proxy);
private:
Instance &_instance;
diff --git a/include/curl_wrapper.hpp b/include/curl_wrapper.hpp
index faf79a5..dcd40ec 100644
--- a/include/curl_wrapper.hpp
+++ b/include/curl_wrapper.hpp
@@ -137,7 +137,7 @@ public:
*
* @since 0.1.0
*/
- void set_proxy(const string_view proxy);
+ void set_proxy(string_view proxy);
protected:
/*!
diff --git a/include/instance.hpp b/include/instance.hpp
index cecb324..28f8f27 100644
--- a/include/instance.hpp
+++ b/include/instance.hpp
@@ -50,8 +50,7 @@ public:
*
* @since 0.1.0
*/
- explicit Instance(const string_view hostname,
- const string_view access_token);
+ explicit Instance(string_view hostname, string_view access_token);
/*!
* @brief Returns the hostname.
diff --git a/src/api.cpp b/src/api.cpp
index d0ffefa..cb60a8b 100644
--- a/src/api.cpp
+++ b/src/api.cpp
@@ -23,6 +23,8 @@ API::API(const endpoint_type &endpoint)
: _endpoint{endpoint}
{}
+// TODO: look for a better way.
+// NOLINTNEXTLINE(cert-err58-cpp)
const map<API::endpoint_type,string_view> API::_endpoint_map
{
{v1::apps, "/api/v1/apps"},