Skip to content

Commit cca538a

Browse files
Fix undeclared reference to env
1 parent 6c279d5 commit cca538a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/lib.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
//!
2121
//! ```
2222
//! use webbrowser;
23-
//!
23+
//!
2424
//! if webbrowser::open("http://github.com").is_ok() {
2525
//! // ...
2626
//! }
@@ -205,7 +205,7 @@ fn open_browser_internal(browser: Browser, url: &str) -> Result<Output> {
205205
/// Open on Linux using the $BROWSER env var
206206
#[cfg(target_os = "linux")]
207207
fn open_on_linux_using_browser_env(url: &str) -> Result<Output> {
208-
let browsers = env::var("BROWSER").map_err(|_| -> Error { Error::new(ErrorKind::NotFound, format!("BROWSER env not set")) })?;
208+
let browsers = ::std::env::var("BROWSER").map_err(|_| -> Error { Error::new(ErrorKind::NotFound, format!("BROWSER env not set")) })?;
209209
for browser in browsers.split(':') { // $BROWSER can contain ':' delimited options, each representing a potential browser command line
210210
if !browser.is_empty() {
211211
// each browser command can have %s to represent URL, while %c needs to be replaced

0 commit comments

Comments
 (0)