summaryrefslogtreecommitdiff
path: root/editor/plugins/animation_state_machine_editor.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'editor/plugins/animation_state_machine_editor.cpp')
-rw-r--r--editor/plugins/animation_state_machine_editor.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/editor/plugins/animation_state_machine_editor.cpp b/editor/plugins/animation_state_machine_editor.cpp
index df7ac0b587..8efd12ecf9 100644
--- a/editor/plugins/animation_state_machine_editor.cpp
+++ b/editor/plugins/animation_state_machine_editor.cpp
@@ -1073,7 +1073,9 @@ void AnimationNodeStateMachineEditor::_name_edited(const String &p_text) {
ERR_FAIL_COND(new_name == "" || new_name.find(".") != -1 || new_name.find("/") != -1)
- ERR_FAIL_COND(new_name == prev_name);
+ if (new_name == prev_name) {
+ return; // Nothing to do.
+ }
String base_name = new_name;
int base = 1;