mirror of
https://github.com/adafruit/RTClib.git
synced 2026-07-27 19:56:05 +00:00
Initializes "hourReformatted" and "isPM" variables
This commit is contained in:
+1
-1
@@ -465,7 +465,7 @@ bool DateTime::isValid() const {
|
||||
char *DateTime::toString(char *buffer) {
|
||||
uint8_t apTag =
|
||||
(strstr(buffer, "ap") != nullptr) || (strstr(buffer, "AP") != nullptr);
|
||||
uint8_t hourReformatted, isPM;
|
||||
uint8_t hourReformatted = 0, isPM = false;
|
||||
if (apTag) { // 12 Hour Mode
|
||||
if (hh == 0) { // midnight
|
||||
isPM = false;
|
||||
|
||||
Reference in New Issue
Block a user