From 3a3b198a4ee27d37f9940dd17989bb7aa7813c18 Mon Sep 17 00:00:00 2001
From: vecpeng <841298391@qq.com>
Date: Sat, 1 Jan 2022 13:05:36 +0800
Subject: [PATCH 1/2] :pencil:docs: add emoji for limations
---
.github/README.md | 2 +-
.github/README_de.md | 2 +-
.github/README_es.md | 2 +-
.github/README_fa.md | 2 +-
.github/README_fr.md | 2 +-
.github/README_he.md | 2 +-
.github/README_id.md | 2 +-
.github/README_it.md | 2 +-
.github/README_ja.md | 2 +-
.github/README_ko.md | 2 +-
.github/README_nl.md | 2 +-
.github/README_pt.md | 2 +-
.github/README_ru.md | 2 +-
.github/README_sa.md | 2 +-
.github/README_tr.md | 2 +-
.github/README_zh-CN.md | 2 +-
.github/README_zh-TW.md | 2 +-
middleware/encryptcookie/encryptcookie_test.go | 3 ++-
18 files changed, 19 insertions(+), 18 deletions(-)
diff --git a/.github/README.md b/.github/README.md
index 2f796920a5..eae61cef5b 100644
--- a/.github/README.md
+++ b/.github/README.md
@@ -142,7 +142,7 @@ Fiber is **inspired** by Express, the most popular web framework on the Internet
We **listen** to our users in [issues](https://github.com/gofiber/fiber/issues), Discord [channel](https://gofiber.io/discord) _and all over the Internet_ to create a **fast**, **flexible** and **friendly** Go web framework for **any** task, **deadline** and developer **skill**! Just like Express does in the JavaScript world.
-## Limitations
+## ⚠️ Limitations
* Due to Fiber's usage of unsafe, the library may not always be compatible with the latest Go version. Fiber 2.18.0 has been tested with Go versions 1.14 to 1.17.
* Fiber is not compatible with net/http interfaces. This means you will not be able to use projects like gqlgen, go-swagger, or any others which are part of the net/http ecosystem.
diff --git a/.github/README_de.md b/.github/README_de.md
index f9736baa7e..517349462a 100644
--- a/.github/README_de.md
+++ b/.github/README_de.md
@@ -140,7 +140,7 @@ Neue Gopher, welche von [Node.js](https://nodejs.org/en/about/) zu [Go](https://
Fiber ist **inspiriert** von Express.js, dem beliebtesten Web-Framework im Internet. Wir haben die **Leichtigkeit** von Express und die **Rohleistung** von Go kombiniert. Wenn du jemals eine Webanwendung mit Node.js implementiert hast (_mit Express.js oder ähnlichem_), werden dir viele Methoden und Prinzipien **sehr vertraut** vorkommen.
-## Limitations
+## ⚠️ Limitations
* Due to Fiber's usage of unsafe, the library may not always be compatible with the latest Go version. Fiber 2.18.0 has been tested with Go versions 1.14 to 1.17.
* Fiber is not compatible with net/http interfaces. This means you will not be able to use projects like gqlgen, go-swagger, or any others which are part of the net/http ecosystem.
diff --git a/.github/README_es.md b/.github/README_es.md
index e2d33cc931..e753e8bca9 100644
--- a/.github/README_es.md
+++ b/.github/README_es.md
@@ -140,7 +140,7 @@ Los nuevos gophers que hacen el cambio de [Node.js](https://nodejs.org/en/about/
Fiber está **inspirado** en Expressjs, el framework web más popular en Internet. Combinamos la **facilidad** de Express y **el rendimiento bruto** de Go. Si alguna vez ha implementado una aplicación web en Node.js ( _utilizando Express.js o similar_ ), muchos métodos y principios le parecerán **muy comunes** .
-## Limitantes
+## ⚠️ Limitantes
* Debido a que Fiber utiliza unsafe, la biblioteca no siempre será compatible con la última versión de Go. Fiber 2.18.0 ha sido probado con las versiones de Go 1.14 a 1.17.
* Fiber no es compatible con interfaces net/http. Esto significa que no lo podrá usar en proyectos como qglgen, go-swagger, u otros que son parte del ecosistema net/http.
diff --git a/.github/README_fa.md b/.github/README_fa.md
index 348931344d..81129bd3bd 100644
--- a/.github/README_fa.md
+++ b/.github/README_fa.md
@@ -180,7 +180,7 @@ Fiber از Express الهام گرفته, که محبوب ترین فری
-## محدودیت ها
+## ⚠️ محدودیت ها
* به دلیل استفاده ناامن از Fiber, ممکن است کتابخانه همیشه با آخرین نسخه Go سازگار نباشد. Fiber 2.18.0 با زبان گو نسخه ۱.۱۴ تا ۱.۱۷ تست شده است.
* فریمورک Fiber با پکیج net/http سازگار نیست. این بدان معناست شما نمی توانید از پکیج های مانند go-swagger, gqlgen یا سایر پروژه هایی که بخشی از اکوسیستم net/http هستند استفاده کنید.
diff --git a/.github/README_fr.md b/.github/README_fr.md
index b83188085e..7e47f6b8dd 100644
--- a/.github/README_fr.md
+++ b/.github/README_fr.md
@@ -140,7 +140,7 @@ Les nouveaux gophers qui passent de [Node.js](https://nodejs.org/en/about/) à [
Fiber est **inspiré** par Express, le framework web le plus populaire d'Internet. Nous avons combiné la **facilité** d'Express, et la **performance brute** de Go. Si vous avez déja développé une application web en Node.js (_en utilisant Express ou équivalent_), alors de nombreuses méthodes et principes vous sembleront **familiers**.
-## Limitations
+## ⚠️ Limitations
* Due to Fiber's usage of unsafe, the library may not always be compatible with the latest Go version. Fiber 2.18.0 has been tested with Go versions 1.14 to 1.17.
* Fiber is not compatible with net/http interfaces. This means you will not be able to use projects like gqlgen, go-swagger, or any others which are part of the net/http ecosystem.
diff --git a/.github/README_he.md b/.github/README_he.md
index 55928aa4e1..f65aac435e 100644
--- a/.github/README_he.md
+++ b/.github/README_he.md
@@ -185,7 +185,7 @@ Fiber נוצרה **בהשראת** Express, ה-web framework הפופולרית
-## Limitations
+## ⚠️ Limitations
* Due to Fiber's usage of unsafe, the library may not always be compatible with the latest Go version. Fiber 2.18.0 has been tested with Go versions 1.14 to 1.17.
* Fiber is not compatible with net/http interfaces. This means you will not be able to use projects like gqlgen, go-swagger, or any others which are part of the net/http ecosystem.
diff --git a/.github/README_id.md b/.github/README_id.md
index e086e6fff2..94391e4a77 100644
--- a/.github/README_id.md
+++ b/.github/README_id.md
@@ -142,7 +142,7 @@ Fiber terinspirasi dari Express, salah satu web framework yang paling terkenal d
Kami **mendengarkan** para pengguna di [GitHub Issues](https://github.com/gofiber/fiber/issues) (_dan berbagai platform lainnya_) untuk menciptakan web framework yang **cepat**, **fleksibel** dan **bersahabat** untuk berbagai macam keperluan, **tenggat waktu** dan **keahlian** para pengguna! Sama halnya seperti yang dilakukan Express di dunia JavaScript.
-## Limitations
+## ⚠️ Limitations
* Due to Fiber's usage of unsafe, the library may not always be compatible with the latest Go version. Fiber 2.18.0 has been tested with Go versions 1.14 to 1.17.
* Fiber is not compatible with net/http interfaces. This means you will not be able to use projects like gqlgen, go-swagger, or any others which are part of the net/http ecosystem.
diff --git a/.github/README_it.md b/.github/README_it.md
index 054b0b55ef..ca3c3996b6 100644
--- a/.github/README_it.md
+++ b/.github/README_it.md
@@ -140,7 +140,7 @@ I nuovi gopher che passano da [Node.js](https://nodejs.org/en/about/) a [Go](htt
Fiber è **inspirato** da Express, il web framework più popolare su internet. Abbiamo combiniamo la **facilità** di Express e **le pure prestazioni** di Go. Se hai mai implementato una applicazione web in Node.js (_utilizzando Express o simili_), allora i tanti metodi e principi ti saranno **molto familiari**.
-## Limitazioni
+## ⚠️ Limitazioni
* Dato che Fiber utilizza unsafe, la libreria non sempre potrebbe essere compatibile con l'ultima versione di Go. Fiber 2.18.0 è stato testato con la versioni 1.14 alla 1.17 di Go.
* Fiber non è compatibile con le interfacce net/http. Questo significa che non è possibile utilizzare progetti come qglgen, go-swagger, o altri che fanno parte dell'ecosistema net/http.
diff --git a/.github/README_ja.md b/.github/README_ja.md
index a5f4c6621f..6c9277dfa2 100644
--- a/.github/README_ja.md
+++ b/.github/README_ja.md
@@ -145,7 +145,7 @@ Fiber は人気の高い Web フレームワークである Expressjs に**イ
わたしたちは Express の**手軽さ**と Go の**パフォーマンス**を組み合わせました。
もしも、Web アプリケーションを Express 等の Node.js フレームワークで実装した経験があれば、多くの方法や原理がとても**馴染み深い**でしょう。
-## 制限時効
+## ⚠️ 制限時効
* Fiberはunsafeパッケージを使用しているため、最新のGoバージョンと互換性がない場合があります。Fiber 2.18.0 は、Go のバージョン 1.14 から 1.17 でテストされています。
* Fiberはnet/httpインターフェースと互換性がありません。つまり、gqlgenやgo-swaggerなど、net/httpのエコシステムの一部であるプロジェクトを使用することができません。
diff --git a/.github/README_ko.md b/.github/README_ko.md
index 95f7c45e6c..addae78ac9 100644
--- a/.github/README_ko.md
+++ b/.github/README_ko.md
@@ -142,7 +142,7 @@ Fiber는 인터넷에서 가장 인기있는 웹 프레임워크인 Express에
우리는 **어떤한** 작업, **마감일정**, 개발자의 **기술**이던간에 **빠르고**, **유연하고**, **익숙한** Go 웹 프레임워크를 만들기 위해 사용자들의 [이슈들](https://github.com/gofiber/fiber/issues)을(그리고 모든 인터넷을 통해) **듣고 있습니다**! Express가 자바스크립트 세계에서 하는 것 처럼요.
-## :warning: 한계점
+## ⚠️ 한계점
* Fiber는 unsafe 패키지를 사용하기 때문에 최신 Go버전과 호환되지 않을 수 있습니다.Fiber 2.18.0은 Go 버전 1.14에서 1.17로 테스트되고 있습니다.
* Fiber는 net/http 인터페이스와 호환되지 않습니다.즉, gqlgen이나 go-swagger 등 net/http 생태계의 일부인 프로젝트를 사용할 수 없습니다.
diff --git a/.github/README_nl.md b/.github/README_nl.md
index 304353efba..2a7b21ed71 100644
--- a/.github/README_nl.md
+++ b/.github/README_nl.md
@@ -142,7 +142,7 @@ Fiber is **geïnspireerd** door Express, het populairste webframework op interne
We **luisteren** naar onze gebruikers in [issues](https://github.com/gofiber/fiber/issues) (_en overal op het internet_) om een **snelle**, **flexibele** en **vriendelijk** Go web framework te maken voor **elke** taak, **deadline** en ontwikkelaar **vaardigheid**! Net zoals Express dat doet in de JavaScript-wereld.
-## Limitations
+## ⚠️ Limitations
* Due to Fiber's usage of unsafe, the library may not always be compatible with the latest Go version. Fiber 2.18.0 has been tested with Go versions 1.14 to 1.17.
* Fiber is not compatible with net/http interfaces. This means you will not be able to use projects like gqlgen, go-swagger, or any others which are part of the net/http ecosystem.
diff --git a/.github/README_pt.md b/.github/README_pt.md
index 5a6986ca5c..60143741c5 100644
--- a/.github/README_pt.md
+++ b/.github/README_pt.md
@@ -140,7 +140,7 @@ Os novos gophers que mudaram do [Node.js](https://nodejs.org/en/about/) para o [
O Fiber é **inspirado** no Express, o framework web mais popular da Internet. Combinamos a **facilidade** do Express e com o **desempenho bruto** do Go. Se você já implementou um aplicativo web com Node.js ( _usando Express.js ou similar_ ), então muitos métodos e princípios parecerão **muito familiares** para você.
-## Limitations
+## ⚠️ Limitations
* Due to Fiber's usage of unsafe, the library may not always be compatible with the latest Go version. Fiber 2.18.0 has been tested with Go versions 1.14 to 1.17.
* Fiber is not compatible with net/http interfaces. This means you will not be able to use projects like gqlgen, go-swagger, or any others which are part of the net/http ecosystem.
diff --git a/.github/README_ru.md b/.github/README_ru.md
index 2e55bbddd6..a17b5e39f4 100644
--- a/.github/README_ru.md
+++ b/.github/README_ru.md
@@ -142,7 +142,7 @@ Fiber **вдохновлен** Express, самым популярным веб
Мы **прислушиваемся** к нашим пользователям в [issues](https://github.com/gofiber/fiber/issues), Discord [канале](https://gofiber.io/discord) _и в остальном Интернете_, чтобы создать **быстрый**, **гибкий** и **дружелюбный** веб фреймворк на Go для **любых** задач, **дедлайнов** и **уровней** разработчиков! Как это делает Express в мире JavaScript.
-## Limitations
+## ⚠️ Limitations
* Due to Fiber's usage of unsafe, the library may not always be compatible with the latest Go version. Fiber 2.18.0 has been tested with Go versions 1.14 to 1.17.
* Fiber is not compatible with net/http interfaces. This means you will not be able to use projects like gqlgen, go-swagger, or any others which are part of the net/http ecosystem.
diff --git a/.github/README_sa.md b/.github/README_sa.md
index 2143a29ec2..39729ee4d1 100644
--- a/.github/README_sa.md
+++ b/.github/README_sa.md
@@ -156,7 +156,7 @@ Fiber هو **مستوحى** من Express, إطار الويب الأكثر شع
نحن **نصغي** لمستخدمينا [issues](https://github.com/gofiber/fiber/issues), نناقش [channel](https://gofiber.io/discord) _وفي جميع أنحاء الإنترنت_ لإنشاء **سريع**, **مرن** و **مألوف** Go إطار الويب لـ **لأي** مهمة, **الموعد الأخير
** و تطوير **مهارات**! فقط مثل Express تفعل لـ JavaScript عالم.
-## Limitations
+## ⚠️ Limitations
* Due to Fiber's usage of unsafe, the library may not always be compatible with the latest Go version. Fiber 2.18.0 has been tested with Go versions 1.14 to 1.17.
* Fiber is not compatible with net/http interfaces. This means you will not be able to use projects like gqlgen, go-swagger, or any others which are part of the net/http ecosystem.
diff --git a/.github/README_tr.md b/.github/README_tr.md
index 5bb9597799..f9fa246848 100644
--- a/.github/README_tr.md
+++ b/.github/README_tr.md
@@ -140,7 +140,7 @@ go get -u github.com/gofiber/fiber/v2
Fiber internet üzerinde en popüler olan Express web frameworkünden **esinlenmiştir**. Biz Express'in **kolaylığını** ve Go'nun **ham performansını** birleştirdik. Daha önce Node.js üzerinde (Express veya benzerini kullanarak) bir web uygulaması geliştirdiyseniz, pek çok metod ve prensip size **çok tanıdık** gelecektir.
-## Sınırlamalar
+## ⚠️ Sınırlamalar
- Fiber unsafe kullanımı sebebiyle her zaman Go'nun son sürümüyle uyumlu olmayabilir. Fiber 2.18.0, Go 1.14 ile 1.17 sürümleriyle test edildi.
- Fiber net/http arabirimiyle uyumlu değildir. Yani gqlgen veya go-swagger gibi net/http ekosisteminin parçası olan projeleri kullanamazsınız.
diff --git a/.github/README_zh-CN.md b/.github/README_zh-CN.md
index ae3487bbd6..18db31a757 100644
--- a/.github/README_zh-CN.md
+++ b/.github/README_zh-CN.md
@@ -142,7 +142,7 @@ go get -u github.com/gofiber/fiber/v2
我们会**倾听**用户在[issues](https://github.com/gofiber/fiber/issues)和 Discord [channel](https://gofiber.io/discord)和在互联网上的所有诉求,为了创建一个能让有着任何技术栈的开发者都能在deadline前完成任务的**迅速**,**灵活**以及**友好**的`Go web`框架,就像`Express`在`JavaScript`世界中一样。
-## 限制
+## ⚠️ 限制
* 由于 Fiber 使用了 unsafe 特性,导致其可能与最新的 Go 版本不兼容。Fiber 2.18.0 已经在 Go 1.14 到 1.17 上测试过。
* Fiber 与 net/http 接口不兼容。也就是说你无法使用 gqlen,go-swagger 或者任何其他属于 net/http 生态的项目。
diff --git a/.github/README_zh-TW.md b/.github/README_zh-TW.md
index a1b047f492..a4206405ed 100644
--- a/.github/README_zh-TW.md
+++ b/.github/README_zh-TW.md
@@ -142,7 +142,7 @@ Fiber **受到** 網路上最流行的 Web 框架 ExpressJS**啟發**,結合 E
有什麼問題請發[issues](https://github.com/gofiber/fiber/issues)或加入 Discord [channel](https://gofiber.io/discord)討論,我們想要創造**快速**、**彈性**、**友善**的社群給**任何人**使用!就像 Express 那樣。
-## Limitations
+## ⚠️ Limitations
* Due to Fiber's usage of unsafe, the library may not always be compatible with the latest Go version. Fiber 2.18.0 has been tested with Go versions 1.14 to 1.17.
* Fiber is not compatible with net/http interfaces. This means you will not be able to use projects like gqlgen, go-swagger, or any others which are part of the net/http ecosystem.
diff --git a/middleware/encryptcookie/encryptcookie_test.go b/middleware/encryptcookie/encryptcookie_test.go
index 74188209bf..1b5f305451 100644
--- a/middleware/encryptcookie/encryptcookie_test.go
+++ b/middleware/encryptcookie/encryptcookie_test.go
@@ -2,6 +2,7 @@ package encryptcookie
import (
"encoding/base64"
+ "github.com/gofiber/fiber/v2/middleware/csrf"
"net/http/httptest"
"testing"
@@ -14,7 +15,7 @@ var testKey = GenerateKey()
func Test_Middleware_Encrypt_Cookie(t *testing.T) {
app := fiber.New()
-
+ app.Use(csrf.New())
app.Use(New(Config{
Key: testKey,
}))
From 0a6c357df6e7b8b5468bc1bf9536c9166d57998f Mon Sep 17 00:00:00 2001
From: vecpeng <841298391@qq.com>
Date: Sat, 1 Jan 2022 15:28:42 +0800
Subject: [PATCH 2/2] :bug:fix: remove debug info
---
middleware/encryptcookie/encryptcookie_test.go | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/middleware/encryptcookie/encryptcookie_test.go b/middleware/encryptcookie/encryptcookie_test.go
index 1b5f305451..74188209bf 100644
--- a/middleware/encryptcookie/encryptcookie_test.go
+++ b/middleware/encryptcookie/encryptcookie_test.go
@@ -2,7 +2,6 @@ package encryptcookie
import (
"encoding/base64"
- "github.com/gofiber/fiber/v2/middleware/csrf"
"net/http/httptest"
"testing"
@@ -15,7 +14,7 @@ var testKey = GenerateKey()
func Test_Middleware_Encrypt_Cookie(t *testing.T) {
app := fiber.New()
- app.Use(csrf.New())
+
app.Use(New(Config{
Key: testKey,
}))