Skip to content
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion crates/cargo-contract/src/cmd/build/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -188,6 +188,8 @@ impl BuildCommand {
false => Network::Online,
};

let skip_linting = self.skip_linting || matches!(network, Network::Offline);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd add a comment as to why we skip linting in this case


let output_type = match self.output_json {
true => OutputType::Json,
false => OutputType::HumanReadable,
Expand All @@ -207,7 +209,7 @@ impl BuildCommand {
unstable_flags,
optimization_passes,
keep_debug_symbols: self.keep_debug_symbols,
skip_linting: self.skip_linting,
skip_linting,
output_type,
};

Expand Down