Skip to content

Commit 7752463

Browse files
authored
Merge pull request #2235 from topecongiro/option_env
Inspect CFG_RELEASE_CHANNEL env var at compile time
2 parents 4018873 + ef4b3d9 commit 7752463

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/config.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,9 @@ use Summary;
2424

2525
macro_rules! is_nightly_channel {
2626
() => {
27-
env::var("CFG_RELEASE_CHANNEL")
28-
.map(|c| c == "nightly")
29-
.unwrap_or(false)
27+
option_env!("CFG_RELEASE_CHANNEL")
28+
.map(|c| c == "nightly")
29+
.unwrap_or(false)
3030
}
3131
}
3232

0 commit comments

Comments
 (0)