mirror of
https://github.com/notohh/rustlings.git
synced 2024-11-21 21:42:23 -05:00
Use var_os to avoid conversion to String
This commit is contained in:
parent
7560aec66b
commit
8ad18de54c
1 changed files with 1 additions and 1 deletions
|
@ -3,7 +3,7 @@ macro_rules! print_emoji {
|
|||
use console::{style, Emoji};
|
||||
use std::env;
|
||||
let formatstr = format!($fmt, $ex);
|
||||
if env::var("NO_EMOJI").is_ok() {
|
||||
if env::var_os("NO_EMOJI").is_some() {
|
||||
println!("{} {}", style($sign).$color(), style(formatstr).$color());
|
||||
} else {
|
||||
println!(
|
||||
|
|
Loading…
Reference in a new issue