Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save tanhit243/18eaccda77cb494a7fcde8810d565846 to your computer and use it in GitHub Desktop.
Save tanhit243/18eaccda77cb494a7fcde8810d565846 to your computer and use it in GitHub Desktop.
:info_neon: Chuyên mục MIL - Monday I learn - 012
Một chút tin tức mới về rails 7.1
1. Github vừa mới public một Mysql client đang được sử dụng trong Github và nó đã được thêm vào rails. Bạn có thể sử dựng nó thay thế cho mysql2.
"Trilogy is a client library for MySQL-compatible database servers, designed for performance, flexibility, and ease of embedding."
Ref: https://github.com/rails/rails/pull/47880
2. Thay đổi cách validate độ dài password với BCrypt. Trước sử dụng count kí tự điều này có thể không thoả mãn validate phía BCrypt là 72 byte. Sau chuyển thành kiểm tra theo byte và thêm một key cho I18n `:password_too_long`.
"This Pull Request has been created because we identified a need to improve password length validation for BCrypt compatibility in the ActiveModel::SecurePassword module. The current validation only considers the character count, which may not accurately reflect the byte size limit imposed by BCrypt."
Ref: https://github.com/rails/rails/pull/47708
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment