We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 1dd80dd + 7b54e0a commit b393df5Copy full SHA for b393df5
1 file changed
browser.go
@@ -6,7 +6,6 @@ package browser
6
import (
7
"fmt"
8
"io"
9
- "io/ioutil"
10
"os"
11
"os/exec"
12
"path/filepath"
@@ -30,7 +29,7 @@ func OpenFile(path string) error {
30
29
// OpenReader consumes the contents of r and presents the
31
// results in a new browser window.
32
func OpenReader(r io.Reader) error {
33
- f, err := ioutil.TempFile("", "browser.*.html")
+ f, err := os.CreateTemp("", "browser.*.html")
34
if err != nil {
35
return fmt.Errorf("browser: could not create temporary file: %w", err)
36
}
0 commit comments