remove uneeded make_optional

This commit is contained in:
Aaron Kimbre 2025-01-02 18:01:45 -06:00
parent fd1ce75380
commit 2ce2f4e363

View File

@ -271,7 +271,7 @@ namespace GeneralUtils {
template <typename T>
[[nodiscard]] std::optional<json> TryParse(const std::string_view str) {
try {
return std::make_optional<json>(json::parse(str));
return json::parse(str);
} catch (const std::exception& e) {
return std::nullopt;
}