You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-11 13:10:58 +00:00
Rename is_valid_integer() to is_valid_int()
Method from `String`
This commit is contained in:
@@ -294,7 +294,7 @@ Error String::parse_url(String &r_scheme, String &r_host, int &r_port, String &r
|
||||
// Port
|
||||
if (base.begins_with(":")) {
|
||||
base = base.substr(1, base.length() - 1);
|
||||
if (!base.is_valid_integer()) {
|
||||
if (!base.is_valid_int()) {
|
||||
return ERR_INVALID_PARAMETER;
|
||||
}
|
||||
r_port = base.to_int();
|
||||
@@ -4168,7 +4168,7 @@ String String::trim_suffix(const String &p_suffix) const {
|
||||
return s;
|
||||
}
|
||||
|
||||
bool String::is_valid_integer() const {
|
||||
bool String::is_valid_int() const {
|
||||
int len = length();
|
||||
|
||||
if (len == 0) {
|
||||
@@ -4393,7 +4393,7 @@ bool String::is_valid_ip_address() const {
|
||||
}
|
||||
for (int i = 0; i < ip.size(); i++) {
|
||||
String n = ip[i];
|
||||
if (!n.is_valid_integer()) {
|
||||
if (!n.is_valid_int()) {
|
||||
return false;
|
||||
}
|
||||
int val = n.to_int();
|
||||
|
||||
Reference in New Issue
Block a user