forked from ProjectSegfault/publapi
Fix newline escape character on /online
Signed-off-by: Odyssey <odyssey346@disroot.org>
This commit is contained in:
parent
a9933f7a42
commit
a10b9a75c2
4
main.go
4
main.go
@ -10,6 +10,8 @@ import (
|
|||||||
log "github.com/sirupsen/logrus"
|
log "github.com/sirupsen/logrus"
|
||||||
|
|
||||||
"runtime"
|
"runtime"
|
||||||
|
|
||||||
|
"strings"
|
||||||
)
|
)
|
||||||
|
|
||||||
// publapi is a simple API for Project Segfault's public shared server (pubnix).
|
// publapi is a simple API for Project Segfault's public shared server (pubnix).
|
||||||
@ -41,7 +43,7 @@ func main() {
|
|||||||
output := string(out)
|
output := string(out)
|
||||||
|
|
||||||
return c.JSON(fiber.Map{
|
return c.JSON(fiber.Map{
|
||||||
"users": output,
|
"users": strings.TrimSuffix(output, "\n"),
|
||||||
"status": c.Response().StatusCode(),
|
"status": c.Response().StatusCode(),
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
Loading…
Reference in New Issue
Block a user