Skip to content

Conversation

FujiwaraNaoto
Copy link
Contributor

abstract

I fixed Date::fromDbStringLocal() bug ,which is mentioned here

Cause of the bug

in Date::fromDbStringLocal(const std::string &datetime)
function std::vector<std::string> &&v = splitString(datetime, " "); is used.

when argument datetime format is YYYY-MM-DD, then v.size() equals 1 and program doesn't pass through if (v.size() == 2).

implementation

  1. add unit test when format YYYY-MM-DD is given.
  2. modify Date::fromDbStringLocal() function to adapt format YYYY-MM-DD. in this case, v.size() is 1

@FujiwaraNaoto
Copy link
Contributor Author

Could you review this pull request?

@an-tao an-tao merged commit cc454e0 into an-tao:master Sep 16, 2025
33 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants