Skip to content
This repository was archived by the owner on Mar 17, 2025. It is now read-only.

Commit 9985342

Browse files
committed
rename setError to checkResponse
1 parent 6a78932 commit 9985342

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

Firebase.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ int Firebase::sendRequest(const char* method, const String& path, const String&
8383
String url = makeURL(path);
8484
_http.begin(_host.c_str(), firebasePort, url.c_str(), true, firebaseFingerprint);
8585
int statusCode = _http.sendRequest(method, (uint8_t*)value.c_str(), value.length());
86-
setError(method, url, statusCode);
86+
checkResponse(method, url, statusCode);
8787
return statusCode;
8888
}
8989

@@ -96,7 +96,7 @@ String Firebase::sendRequestGetBody(const char* method, const String& path, cons
9696
return _http.getString();
9797
}
9898

99-
void Firebase::setError(const char* method, const String& url, int statusCode) {
99+
void Firebase::checkResponse(const char* method, const String& url, int statusCode) {
100100
_error.reset();
101101
if (statusCode < 0) {
102102
_error.set(statusCode,

Firebase.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ class Firebase {
6666
String makeURL(const String& path);
6767
int sendRequest(const char* method, const String& path, const String& value = "");
6868
String sendRequestGetBody(const char* method, const String& path, const String& value = "");
69-
void setError(const char* method, const String& url, int status_code);
69+
void checkResponse(const char* method, const String& url, int status_code);
7070

7171
HTTPClient _http;
7272
String _host;

0 commit comments

Comments
 (0)