Skip to content

Commit

Permalink
revised based on reviwer's opinion
Browse files Browse the repository at this point in the history
  • Loading branch information
cheniujh committed Jul 11, 2023
1 parent 24d123e commit 7d90230
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
2 changes: 1 addition & 1 deletion include/pika_command.h
Original file line number Diff line number Diff line change
Expand Up @@ -408,7 +408,7 @@ class CmdRes {
struct UnblockTaskArgs {
std::string key;
std::shared_ptr<Slot> slot;
net::DispatchThread* dispatchThread;
net::DispatchThread* dispatchThread{nullptr};
UnblockTaskArgs(std::string key_, std::shared_ptr<Slot> slot_, net::DispatchThread* dispatchThread_)
: key(std::move(key_)), slot(slot_), dispatchThread(dispatchThread_) {}
};
Expand Down
6 changes: 2 additions & 4 deletions include/pika_list.h
Original file line number Diff line number Diff line change
Expand Up @@ -99,8 +99,7 @@ class BLPopCmd final : public BlockingBaseCmd {
public:
BLPopCmd(const std::string& name, int arity, uint16_t flag) : BlockingBaseCmd(name, arity, flag){};
virtual std::vector<std::string> current_key() const {
std::vector<std::string> res = keys_;
return res;
return {keys_};
}
virtual void Do(std::shared_ptr<Slot> slot = nullptr);
virtual void Split(std::shared_ptr<Slot> slot, const HintKeys& hint_keys){};
Expand Down Expand Up @@ -258,8 +257,7 @@ class BRPopCmd final : public BlockingBaseCmd {
public:
BRPopCmd(const std::string& name, int arity, uint16_t flag) : BlockingBaseCmd(name, arity, flag){};
virtual std::vector<std::string> current_key() const {
std::vector<std::string> res = keys_;
return res;
return {keys_};
}
virtual void Do(std::shared_ptr<Slot> slot = nullptr);
virtual void Split(std::shared_ptr<Slot> slot, const HintKeys& hint_keys){};
Expand Down

0 comments on commit 7d90230

Please sign in to comment.