Remove ': null' from JSON output
This commit is contained in:
parent
4e410d4db2
commit
b17a21b846
|
@ -5,6 +5,7 @@ Copyright © 2024 Seednode <seednode@seedno.de>
|
||||||
package cmd
|
package cmd
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
"bytes"
|
||||||
"encoding/gob"
|
"encoding/gob"
|
||||||
"encoding/json"
|
"encoding/json"
|
||||||
"fmt"
|
"fmt"
|
||||||
|
@ -57,7 +58,7 @@ func makeTree(list []string) ([]byte, error) {
|
||||||
return []byte{}, err
|
return []byte{}, err
|
||||||
}
|
}
|
||||||
|
|
||||||
return resp, nil
|
return bytes.ReplaceAll(resp, []byte(": null"), []byte{}), nil
|
||||||
}
|
}
|
||||||
|
|
||||||
func (index *fileIndex) List() []string {
|
func (index *fileIndex) List() []string {
|
||||||
|
|
|
@ -17,7 +17,7 @@ import (
|
||||||
|
|
||||||
const (
|
const (
|
||||||
AllowedCharacters string = `^[A-z0-9.\-_]+$`
|
AllowedCharacters string = `^[A-z0-9.\-_]+$`
|
||||||
ReleaseVersion string = "8.6.0"
|
ReleaseVersion string = "8.6.1"
|
||||||
)
|
)
|
||||||
|
|
||||||
var (
|
var (
|
||||||
|
|
Loading…
Reference in New Issue