mirror of
https://github.com/aljazceru/signal-cli-rest-api.git
synced 2025-12-19 23:54:22 +01:00
use "--output=json" instead of "--json" when calling signal-cli receive
* --json is deprecated see #103
This commit is contained in:
@@ -605,7 +605,7 @@ func (a *Api) Receive(c *gin.Context) {
|
|||||||
|
|
||||||
timeout := c.DefaultQuery("timeout", "1")
|
timeout := c.DefaultQuery("timeout", "1")
|
||||||
|
|
||||||
command := []string{"--config", a.signalCliConfig, "-u", number, "receive", "-t", timeout, "--json"}
|
command := []string{"--config", a.signalCliConfig, "--output", "json", "-u", number, "receive", "-t", timeout}
|
||||||
out, err := runSignalCli(true, command, "")
|
out, err := runSignalCli(true, command, "")
|
||||||
if err != nil {
|
if err != nil {
|
||||||
c.JSON(400, gin.H{"error": err.Error()})
|
c.JSON(400, gin.H{"error": err.Error()})
|
||||||
|
|||||||
Reference in New Issue
Block a user