mirror of
https://github.com/duke-git/lancet.git
synced 2026-02-04 12:52:28 +08:00
fix: os.go/ExecCommand make error the last return value
This commit is contained in:
@@ -67,7 +67,7 @@ func ContainLetter(str string) bool {
|
||||
return containLetterRegexMatcher.MatchString(str)
|
||||
}
|
||||
|
||||
// Is checks if the string is valid JSON
|
||||
// IsJSON checks if the string is valid JSON
|
||||
func IsJSON(str string) bool {
|
||||
var js json.RawMessage
|
||||
return json.Unmarshal([]byte(str), &js) == nil
|
||||
|
||||
Reference in New Issue
Block a user