Skip to content

Commit 211c7f5

Browse files
authored
Merge pull request #2208 from joto/cleanup-flex-table-col
Fix unusual member name in column_type_lookup
2 parents 23b6634 + 7acd35f commit 211c7f5

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

src/flex-table-column.cpp

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,13 @@
88
*/
99

1010
#include "flex-table-column.hpp"
11+
1112
#include "format.hpp"
1213
#include "pgsql-capabilities.hpp"
1314
#include "util.hpp"
1415

1516
#include <algorithm>
17+
#include <cassert>
1618
#include <cctype>
1719
#include <cstdlib>
1820
#include <stdexcept>
@@ -24,12 +26,12 @@ namespace {
2426
struct column_type_lookup
2527
{
2628
char const *m_name;
27-
table_column_type type;
29+
table_column_type m_type;
2830

2931
char const *name() const noexcept { return m_name; }
3032
};
3133

32-
static std::vector<column_type_lookup> const column_types = {
34+
std::vector<column_type_lookup> const column_types = {
3335
{{"text", table_column_type::text},
3436
{"boolean", table_column_type::boolean},
3537
{"bool", table_column_type::boolean},
@@ -63,7 +65,7 @@ table_column_type get_column_type_from_string(std::string const &type)
6365
throw fmt_error("Unknown column type '{}'.", type);
6466
}
6567

66-
return column_type->type;
68+
return column_type->m_type;
6769
}
6870

6971
std::string lowercase(std::string const &str)

0 commit comments

Comments
 (0)