Skip to content

Commit

Permalink
fix description: null
Browse files Browse the repository at this point in the history
  • Loading branch information
simonpintarelli committed Sep 4, 2024
1 parent eb8f42f commit f261da4
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/uenv/meta.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,9 @@ util::expected<meta, std::string> load_meta(const std::filesystem::path& file) {
const std::string name = raw.contains("name") ? raw["name"] : "unnamed";
using ostring = std::optional<std::string>;
const ostring description =
raw.contains("description") ? ostring(raw["description"]) : ostring{};
raw.contains("description") && !raw["description"].is_null()
? ostring(raw["description"])
: ostring{};
const ostring mount =
raw.contains("mount") ? ostring(raw["mount"]) : ostring{};

Expand Down

0 comments on commit f261da4

Please sign in to comment.