summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/postgresHandler.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/postgresHandler.cpp b/src/postgresHandler.cpp
index a92faaf..256bf06 100644
--- a/src/postgresHandler.cpp
+++ b/src/postgresHandler.cpp
@@ -20,7 +20,7 @@ void display_query_result(const pqxx::result &t_r) {
void add_cards_to_database(const std::string &t_cards, pqxx::work &t_tx) {
// TODO: to complete
std::cout << "adding cards..." << std::endl;
- std::regex key_regex("(\".*\"),"); // TODO: write correct regex
+ std::regex key_regex("\"(.*?)\":"); // TODO: write correct regex
auto words_begin =
std::sregex_iterator(t_cards.begin(), t_cards.end(), key_regex);
auto words_end = std::sregex_iterator();