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

fix: fix ExpectedStale error when expired type is string #2682

Merged

Conversation

wangshao1
Copy link
Collaborator

ExpectedStale didn't consider string type, so if the mismatched key type is string and it's expired, ExpectedStale returns wrong

@github-actions github-actions bot added the ☢️ Bug Something isn't working label May 28, 2024
@@ -406,19 +406,16 @@ class Redis {
auto meta_type = static_cast<enum DataType>(static_cast<uint8_t>(meta_value[0]));
if (meta_type == DataType::kZSets || meta_type == DataType::kSets || meta_type == DataType::kHashes) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这里整体逻辑改为 switch-case 形式吧

@AlexStocks AlexStocks merged commit 2962bf4 into OpenAtomFoundation:unstable May 29, 2024
12 checks passed
AlexStocks added a commit that referenced this pull request May 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
4.0.0 ☢️ Bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants