diff --git a/Cargo.toml b/Cargo.toml index aa25ae5..b36eb3a 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -2,7 +2,7 @@ name = "is-ip" version = "0.1.0" authors = ["hiql "] -categories = ["Network programming"] +categories = ["network-programming"] description = "Check if a string is an IP address" documentation = "https://docs.rs/is-ip" edition = "2021" diff --git a/README.md b/README.md index cc0e594..b9ecdfb 100644 --- a/README.md +++ b/README.md @@ -26,19 +26,19 @@ is_ipv4("1:2:3:4:5:6:7:8"); ## API -#### is_ip(string: &str) -> bool +### is_ip(string: &str) -> bool Check if `string` is IPv6 or IPv4. -#### is_ipv4(string: &str) -> bool +### is_ipv4(string: &str) -> bool Check if `string` is IPv4. -#### is_ipv6(string: &str) -> bool +### is_ipv6(string: &str) -> bool Check if `string` is IPv6. -#### ip_version(string: &str) -> Option +### ip_version(string: &str) -> Option Returns `Some(6)` if `string` is IPv6, `Some(4)` if `string` is IPv4, or `None` if `string` is neither.