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

format codes again #8

Merged
merged 1 commit into from
May 27, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/pika_admin.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1098,7 +1098,7 @@ void InfoCmd::InfoKeyspace(std::string& info) {
if (rescan_) {
g_pika_server->DoSameThingSpecificTable(TaskType::kStartKeyScan, keyspace_scan_tables_);
}
}
}

void InfoCmd::InfoData(std::string& info) {
std::stringstream tmp_stream;
Expand Down
6 changes: 3 additions & 3 deletions src/pika_bit.cc
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ void BitGetCmd::DoInitial() {
res_.SetRes(CmdRes::kInvalidBitOffsetInt);
return;
}
}
}

void BitGetCmd::Do(std::shared_ptr<Partition> partition) {
int32_t bit_val = 0;
Expand Down Expand Up @@ -96,7 +96,7 @@ void BitCountCmd::DoInitial() {
} else {
res_.SetRes(CmdRes::kSyntaxErr, kCmdNameBitCount);
}
}
}

void BitCountCmd::Do(std::shared_ptr<Partition> partition) {
int32_t count = 0;
Expand Down Expand Up @@ -204,7 +204,7 @@ void BitOpCmd::DoInitial() {
for (unsigned int i = 3; i <= argv_.size() - 1; i++) {
src_keys_.emplace_back(argv_[i].data());
}
}
}

void BitOpCmd::Do(std::shared_ptr<Partition> partition) {
int64_t result_length;
Expand Down
20 changes: 12 additions & 8 deletions src/pika_geohash_helper.cc
Original file line number Diff line number Diff line change
Expand Up @@ -166,14 +166,18 @@ GeoHashRadius geohashGetAreasByRadius(double longitude, double latitude, double
geohashDecode(long_range, lat_range, neighbors.east, &east);
geohashDecode(long_range, lat_range, neighbors.west, &west);

if (geohashGetDistance(longitude, latitude, longitude, north.latitude.max) < radius_meters) { decrease_step = 1;
}
if (geohashGetDistance(longitude, latitude, longitude, south.latitude.min) < radius_meters) { decrease_step = 1;
}
if (geohashGetDistance(longitude, latitude, east.longitude.max, latitude) < radius_meters) { decrease_step = 1;
}
if (geohashGetDistance(longitude, latitude, west.longitude.min, latitude) < radius_meters) { decrease_step = 1;
}
if (geohashGetDistance(longitude, latitude, longitude, north.latitude.max) < radius_meters) {
decrease_step = 1;
}
if (geohashGetDistance(longitude, latitude, longitude, south.latitude.min) < radius_meters) {
decrease_step = 1;
}
if (geohashGetDistance(longitude, latitude, east.longitude.max, latitude) < radius_meters) {
decrease_step = 1;
}
if (geohashGetDistance(longitude, latitude, west.longitude.min, latitude) < radius_meters) {
decrease_step = 1;
}
}

if (steps > 1 && (decrease_step != 0)) {
Expand Down