diff options
| author | Rémi Verschelde <remi@verschelde.fr> | 2021-12-10 08:56:31 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-12-10 08:56:31 +0100 |
| commit | bdf8340e5993ec3f86e4bf1d5ede48df7d023a12 (patch) | |
| tree | 1e366583662397e366d4f84bb334660db37cb5bd /scene/animation/animation_player.cpp | |
| parent | 5ad9d8bad69309d71ea55f3d799af7e3711dc262 (diff) | |
| parent | 49403cbfa0399bb4284ea5c36cc90216a0bda6ff (diff) | |
| download | redot-engine-bdf8340e5993ec3f86e4bf1d5ede48df7d023a12.tar.gz | |
Merge pull request #43181 from nathanfranke/string-empty
Replace String comparisons with "", String() to is_empty()
Diffstat (limited to 'scene/animation/animation_player.cpp')
| -rw-r--r-- | scene/animation/animation_player.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/scene/animation/animation_player.cpp b/scene/animation/animation_player.cpp index b9435b6692..d603106696 100644 --- a/scene/animation/animation_player.cpp +++ b/scene/animation/animation_player.cpp @@ -1416,7 +1416,7 @@ bool AnimationPlayer::is_playing() const { } void AnimationPlayer::set_current_animation(const String &p_anim) { - if (p_anim == "[stop]" || p_anim == "") { + if (p_anim == "[stop]" || p_anim.is_empty()) { stop(); } else if (!is_playing() || playback.assigned != p_anim) { play(p_anim); |
