Skip to content

Commit

Permalink
chore: make metadata values json objects and do not serialize if empty
Browse files Browse the repository at this point in the history
  • Loading branch information
elfedy committed Nov 27, 2024
1 parent 2cf53af commit c2a6c68
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions crates/compilers/src/compilers/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -209,8 +209,8 @@ pub struct CompilerOutput<E, C> {
pub contracts: FileToContractsMap<C>,
#[serde(default)]
pub sources: BTreeMap<PathBuf, SourceFile>,
#[serde(default)]
pub metadata: BTreeMap<String, String>,
#[serde(default, skip_serializing_if = "::std::collections::BTreeMap::is_empty")]
pub metadata: BTreeMap<String, serde_json::Value>,
}

impl<E, C> CompilerOutput<E, C> {
Expand Down

0 comments on commit c2a6c68

Please sign in to comment.