Skip to content

Commit

Permalink
fix variable scope
Browse files Browse the repository at this point in the history
  • Loading branch information
odygrd authored Nov 5, 2023
1 parent e27d120 commit cf109a1
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions quill/src/detail/backend/StringFromTime.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -276,16 +276,11 @@ std::string const& StringFromTime::format_timestamp(time_t timestamp)
/***/
void StringFromTime::_populate_initial_parts(std::string timestamp_format)
{
std::string part1;
std::string part2;

do
{
// we get part1 and part2 and keep looping on the new modified string without the part1 and
// part2 until we find not %H, %M or %S at all
auto const pp = _split_timestamp_format_once(timestamp_format);
part1 = pp.first;
part2 = pp.second;
auto const [part1, part2] = _split_timestamp_format_once(timestamp_format);

if (!part1.empty())
{
Expand Down

0 comments on commit cf109a1

Please sign in to comment.