diff options
| author | Jacky Zhao <[email protected]> | 2021-03-08 00:05:08 -0800 |
|---|---|---|
| committer | GitHub <[email protected]> | 2021-03-08 00:05:08 -0800 |
| commit | 9aa8dc921f03a08ca8987e4ca3f3f66a1f4b4981 (patch) | |
| tree | bffadcdef97795ce411231a74207f48165dcb96a /backend/db | |
| parent | css fix (diff) | |
| parent | remove ip from hash calculation (diff) | |
| download | ctrl-v-9aa8dc921f03a08ca8987e4ca3f3f66a1f4b4981.tar.xz ctrl-v-9aa8dc921f03a08ca8987e4ca3f3f66a1f4b4981.zip | |
Merge pull request #72 from jackyzha0/no-ip
Diffstat (limited to 'backend/db')
| -rw-r--r-- | backend/db/db.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/backend/db/db.go b/backend/db/db.go index af68262..a9631af 100644 --- a/backend/db/db.go +++ b/backend/db/db.go @@ -29,9 +29,9 @@ const TitleLimit = 100 const ContentLimit = 100000 // creates a new paste with title, content and hash, returns the hash of the created paste -func New(ip, content, expiry, title, password, lang string) (string, error) { +func New(content, expiry, title, password, lang string) (string, error) { // generate hash from ip - hash := security.GenerateURI(ip) + hash := security.GenerateURI(content) // check for size of title and content errs := checkLengths(title, content) |