From 0a83ee0c68e47208006c790890fd9b73f76356c6 Mon Sep 17 00:00:00 2001 From: andrejlevkovitch Date: Thu, 4 Jun 2020 21:15:08 +0300 Subject: [PATCH] remove {} from one line if --- src/json-validator.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/json-validator.cpp b/src/json-validator.cpp index f497aea..47b16f5 100644 --- a/src/json-validator.cpp +++ b/src/json-validator.cpp @@ -672,9 +672,8 @@ public: attr = sch.find("format"); if (attr != sch.end()) { - if (root_->format_check() == nullptr) { + if (root_->format_check() == nullptr) throw std::invalid_argument{"a format checker was not provided but a format keyword for this string is present: " + format_.second}; - } format_ = {true, attr.value()}; sch.erase(attr);