mirror of
https://codeberg.org/scip/valpass.git
synced 2025-12-16 20:21:00 +01:00
fix linters, go to v2
This commit is contained in:
@@ -58,7 +58,11 @@ func ReadDict(path string) []string {
|
|||||||
if err != nil {
|
if err != nil {
|
||||||
panic(err)
|
panic(err)
|
||||||
}
|
}
|
||||||
defer file.Close()
|
defer func() {
|
||||||
|
if err := file.Close(); err != nil {
|
||||||
|
log.Fatal(err)
|
||||||
|
}
|
||||||
|
}()
|
||||||
|
|
||||||
var lines []string
|
var lines []string
|
||||||
scanner := bufio.NewScanner(file)
|
scanner := bufio.NewScanner(file)
|
||||||
|
|||||||
4
go.mod
4
go.mod
@@ -1,5 +1,5 @@
|
|||||||
module codeberg.org/scip/valpass
|
module codeberg.org/scip/valpass/v2
|
||||||
|
|
||||||
go 1.22
|
go 1.24
|
||||||
|
|
||||||
require github.com/alecthomas/repr v0.4.0 // indirect
|
require github.com/alecthomas/repr v0.4.0 // indirect
|
||||||
|
|||||||
@@ -3,6 +3,7 @@ package valpass_test
|
|||||||
import (
|
import (
|
||||||
"bufio"
|
"bufio"
|
||||||
"fmt"
|
"fmt"
|
||||||
|
"log"
|
||||||
"os"
|
"os"
|
||||||
"os/exec"
|
"os/exec"
|
||||||
"strings"
|
"strings"
|
||||||
@@ -372,7 +373,11 @@ func ReadDict(path string) []string {
|
|||||||
if err != nil {
|
if err != nil {
|
||||||
panic(err)
|
panic(err)
|
||||||
}
|
}
|
||||||
defer file.Close()
|
defer func() {
|
||||||
|
if err := file.Close(); err != nil {
|
||||||
|
log.Fatal(err)
|
||||||
|
}
|
||||||
|
}()
|
||||||
|
|
||||||
var lines []string
|
var lines []string
|
||||||
scanner := bufio.NewScanner(file)
|
scanner := bufio.NewScanner(file)
|
||||||
|
|||||||
Reference in New Issue
Block a user