Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improved some conditions #1386

Merged
merged 16 commits into from Jun 17, 2021
Merged

Improved some conditions #1386

merged 16 commits into from Jun 17, 2021

Conversation

Ja7ad
Copy link
Contributor

@Ja7ad Ja7ad commented Jun 16, 2021

No description provided.

utils/http.go Outdated Show resolved Hide resolved
internal/msgp/write_bytes.go Outdated Show resolved Hide resolved
@ReneWerner87 ReneWerner87 merged commit 7609117 into gofiber:master Jun 17, 2021
ReneWerner87 added a commit that referenced this pull request Aug 30, 2021
* simplify `u <= (1<<7)-1` to `u < (1 << 7)`

* It's not recommended to use `len` for empty string, we can check with string with ""

* It's not recommended to use `len` for empty string, we can check with string with ""

* It's not recommended to use `len` for empty string, we can check with string with ""

* It's not recommended to use `len` for empty string, we can check with string with ""

* Instead Bool comparison can using simplified bool check if !var = false checking

* Unnecessary use of fmt.Sprintf for value without format

* For check condition two value not required ! method

* nil check may not be enough for slice, better check with len

* function parameters combined

* When the form returns error information, the text content should not start with a capital letter or end with a punctuation mark

* error var invalidPath should have name of the form errFoo, It is recommended that the error variables that are part of an API should be named

* change to condition len(x), it's faster #1386 (comment)

* Update write.go

* Update write_bytes.go

* Update store.go

* Adapted paragraph fiber version compatible with go

* add translated paragraph net/http interfaces limitation

Co-authored-by: RW <rene@gofiber.io>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants