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

refactor: rename ada_get_host_type #487

Merged
merged 1 commit into from
Aug 28, 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 include/ada_c.h
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ ada_string ada_get_hostname(ada_url result);
ada_string ada_get_pathname(ada_url result);
ada_string ada_get_search(ada_url result);
ada_string ada_get_protocol(ada_url result);
uint8_t ada_get_url_host_type(ada_url result);
uint8_t ada_get_host_type(ada_url result);

// url_aggregator setters
// if ada_is_valid(result)) is false, the setters have no effect
Expand Down
2 changes: 1 addition & 1 deletion src/ada_c.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ ada_string ada_get_protocol(ada_url result) noexcept {
return ada_string_create(out.data(), out.length());
}

uint8_t ada_get_url_host_type(ada_url result) noexcept {
uint8_t ada_get_host_type(ada_url result) noexcept {
ada::result<ada::url_aggregator>& r = get_instance(result);
if (!r) {
return 0;
Expand Down
2 changes: 1 addition & 1 deletion tests/ada_c.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ TEST(ada_c, setters) {
ada_set_protocol(url, "wss", 3);
ASSERT_EQ(convert_string(ada_get_protocol(url)), "wss:");

ASSERT_EQ(ada_get_url_host_type(url), 0);
ASSERT_EQ(ada_get_host_type(url), 0);

ada_free(url);

Expand Down
Loading