Skip to content

Commit

Permalink
Merge pull request #12 from Invoca/TECH-15245_use_sha1_digest
Browse files Browse the repository at this point in the history
Tech 15245 use sha1 digest
  • Loading branch information
hislopzach authored Oct 15, 2024
2 parents a947eb9 + ae7eb55 commit 8cc1e73
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 4 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@ Inspired by [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).

Note: this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [0.3.0] - 2024-10-15
### Changed
- Use Digest::SHA1 instead of Digest::SHA256 for hex_digest.

## [0.2.0] - 2023-05-16
### Fixed
- Lua Numbers without decimals will now be converted to integer strings.
Expand Down
4 changes: 2 additions & 2 deletions Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
PATH
remote: .
specs:
mock_redis_lua_extension2 (0.2.0)
mock_redis_lua_extension2 (0.3.0)
mock_redis
rufus-lua

Expand All @@ -10,7 +10,7 @@ GEM
specs:
coderay (1.1.2)
diff-lcs (1.3)
ffi (1.15.5)
ffi (1.17.0)
method_source (1.0.0)
mock_redis (0.28.0)
ruby2_keywords
Expand Down
2 changes: 1 addition & 1 deletion lib/mock_redis_lua_extension.rb
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ def script(subcmd, *args)
when :load
args.count == 1 or raise ArgumentError, "Invalid args: #{args.inspect}"
script = args.first
Digest::SHA256.hexdigest(script).tap do |sha|
Digest::SHA1.hexdigest(script).tap do |sha|
script_catalog[sha] = script
end
when :flush
Expand Down
2 changes: 1 addition & 1 deletion lib/mock_redis_lua_extension/version.rb
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
module MockRedisLuaExtension
VERSION = "0.2.0".freeze
VERSION = "0.3.0".freeze
end

0 comments on commit 8cc1e73

Please sign in to comment.