mirror of
https://github.com/matrix-org/dendrite.git
synced 2025-12-23 14:53:10 -06:00
convert remaining uses of encoding/json to jsoniter
This commit is contained in:
parent
1f2d7d61e2
commit
8e922fb3c6
|
|
@ -15,7 +15,7 @@
|
|||
package routing
|
||||
|
||||
import (
|
||||
"encoding/json"
|
||||
json "github.com/json-iterator/go"
|
||||
"fmt"
|
||||
"net/http"
|
||||
"strconv"
|
||||
|
|
|
|||
|
|
@ -16,7 +16,7 @@ package routing
|
|||
|
||||
import (
|
||||
"context"
|
||||
"encoding/json"
|
||||
json "github.com/json-iterator/go"
|
||||
"net/http"
|
||||
"time"
|
||||
|
||||
|
|
|
|||
|
|
@ -16,7 +16,6 @@ package routing
|
|||
|
||||
import (
|
||||
"context"
|
||||
stdjson "encoding/json"
|
||||
"fmt"
|
||||
json "github.com/json-iterator/go"
|
||||
"net/http"
|
||||
|
|
@ -56,7 +55,7 @@ func Send(
|
|||
}
|
||||
|
||||
var txnEvents struct {
|
||||
PDUs []stdjson.RawMessage `json:"pdus"`
|
||||
PDUs []json.RawMessage `json:"pdus"`
|
||||
EDUs []gomatrixserverlib.EDU `json:"edus"`
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@ package routing
|
|||
|
||||
import (
|
||||
"context"
|
||||
"encoding/json"
|
||||
json "github.com/json-iterator/go"
|
||||
"fmt"
|
||||
"reflect"
|
||||
"testing"
|
||||
|
|
|
|||
|
|
@ -16,7 +16,6 @@ package consumers
|
|||
|
||||
import (
|
||||
"context"
|
||||
stdjson "encoding/json"
|
||||
"fmt"
|
||||
json "github.com/json-iterator/go"
|
||||
|
||||
|
|
@ -121,7 +120,7 @@ func (t *OutputEDUConsumer) onSendToDeviceEvent(msg *sarama.ConsumerMessage) err
|
|||
Sender: ote.Sender,
|
||||
Type: ote.Type,
|
||||
MessageID: util.RandomString(32),
|
||||
Messages: map[string]map[string]stdjson.RawMessage{
|
||||
Messages: map[string]map[string]json.RawMessage{
|
||||
ote.UserID: {
|
||||
ote.DeviceID: ote.Content,
|
||||
},
|
||||
|
|
|
|||
|
|
@ -16,7 +16,7 @@ package queue
|
|||
|
||||
import (
|
||||
"context"
|
||||
"encoding/json"
|
||||
json "github.com/json-iterator/go"
|
||||
"fmt"
|
||||
"sync"
|
||||
"time"
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@ package storage_test
|
|||
import (
|
||||
"context"
|
||||
"crypto/ed25519"
|
||||
"encoding/json"
|
||||
json "github.com/json-iterator/go"
|
||||
"fmt"
|
||||
"os"
|
||||
"testing"
|
||||
|
|
|
|||
Loading…
Reference in a new issue