Skip to content

Commit

Permalink
Change "github.com/json-iterator/go" to “encoding/json”
Browse files Browse the repository at this point in the history
  • Loading branch information
andeya committed Nov 9, 2017
1 parent 99f03cc commit 091feb1
Show file tree
Hide file tree
Showing 57 changed files with 14 additions and 8,863 deletions.
3 changes: 1 addition & 2 deletions apidoc.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,15 +18,14 @@ package faygo

import (
"bytes"
"encoding/json"
"fmt"
"io/ioutil"
"net/http"
"path"
"regexp"
"strings"

json "github.com/json-iterator/go"

"github.com/henrylee2cn/faygo/swagger"
)

Expand Down
3 changes: 1 addition & 2 deletions apiware/util.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,9 @@ package apiware

import (
"bytes"
"encoding/json"
"reflect"
"strings"

json "github.com/json-iterator/go"
)

func toSnake(s string) string {
Expand Down
3 changes: 1 addition & 2 deletions context.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
package faygo

import (
"encoding/json"
"errors"
"fmt"
"math"
Expand All @@ -25,8 +26,6 @@ import (
"path"
"sync"

json "github.com/json-iterator/go"

"github.com/henrylee2cn/faygo/logging"
"github.com/henrylee2cn/faygo/session"
)
Expand Down
3 changes: 1 addition & 2 deletions context_input.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ import (
"crypto/hmac"
"crypto/sha1"
"encoding/base64"
"encoding/json"
"encoding/xml"
"errors"
"fmt"
Expand All @@ -34,8 +35,6 @@ import (
"strconv"
"strings"

json "github.com/json-iterator/go"

"github.com/henrylee2cn/faygo/apiware"
)

Expand Down
3 changes: 1 addition & 2 deletions context_output.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ import (
"crypto/hmac"
"crypto/sha1"
"encoding/base64"
"encoding/json"
"encoding/xml"
"fmt"
"html/template"
Expand All @@ -28,8 +29,6 @@ import (
"time"
"unsafe"

json "github.com/json-iterator/go"

"github.com/henrylee2cn/faygo/acceptencoder"
)

Expand Down
3 changes: 1 addition & 2 deletions ext/db/directsql/sqlhandle.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,11 @@ package directsql

import (
"bytes"
"encoding/json"
"errors"
"html/template"
"io/ioutil"

json "github.com/json-iterator/go"

"github.com/henrylee2cn/faygo"
)

Expand Down
3 changes: 1 addition & 2 deletions ext/db/directsql/sqlhelper.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,13 @@
package directsql

import (
"encoding/json"
"errors"
"fmt"
"reflect"
"strconv"
"time"

json "github.com/json-iterator/go"

"github.com/go-xorm/core"
)

Expand Down
3 changes: 1 addition & 2 deletions faygo.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ package faygo

import (
"context"
"encoding/json"
"fmt"
"net/http"
"os"
Expand All @@ -25,8 +26,6 @@ import (
"sync/atomic"
"time"

json "github.com/json-iterator/go"

"github.com/henrylee2cn/faygo/acceptencoder"
"github.com/henrylee2cn/faygo/apiware"
"github.com/henrylee2cn/faygo/logging"
Expand Down
3 changes: 1 addition & 2 deletions samples/directsql/common/pongo2func.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,9 @@
package common

import (
"encoding/json"
"strings"

json "github.com/json-iterator/go"

"github.com/henrylee2cn/faygo"
"github.com/henrylee2cn/faygo/ext/db/directsql"
"github.com/henrylee2cn/faygo/pongo2"
Expand Down
3 changes: 1 addition & 2 deletions session/sess_cookie.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,11 @@ package session
import (
"crypto/aes"
"crypto/cipher"
"encoding/json"
"net/http"
"net/url"
"sync"

json "github.com/json-iterator/go"

"github.com/henrylee2cn/goutil"
)

Expand Down
3 changes: 1 addition & 2 deletions session/sess_cookie_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,11 @@
package session

import (
"encoding/json"
"net/http"
"net/http/httptest"
"strings"
"testing"

json "github.com/json-iterator/go"
)

func TestCookie(t *testing.T) {
Expand Down
3 changes: 1 addition & 2 deletions session/sess_mem_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,11 @@
package session

import (
"encoding/json"
"net/http"
"net/http/httptest"
"strings"
"testing"

json "github.com/json-iterator/go"
)

func TestMem(t *testing.T) {
Expand Down
3 changes: 1 addition & 2 deletions session/sess_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,8 @@ package session

import (
"crypto/aes"
"encoding/json"
"testing"

json "github.com/json-iterator/go"
)

func Test_gob(t *testing.T) {
Expand Down
21 changes: 0 additions & 21 deletions vendor/github.com/json-iterator/go/LICENSE

This file was deleted.

80 changes: 0 additions & 80 deletions vendor/github.com/json-iterator/go/README.md

This file was deleted.

Loading

0 comments on commit 091feb1

Please sign in to comment.