fixed signal out of scope issue with use_raf_fn.

Fixes #135
This commit is contained in:
Maccesch 2024-07-26 10:18:09 +01:00
parent 37f16ad37b
commit c6005079e1
2 changed files with 2 additions and 1 deletions

View file

@ -70,6 +70,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Fixed auto-reconnect in `use_websocket`
- Fixed typo in compiler error messages in `use_cookie` (thanks to @SleeplessOne1917).
- Fixed potential signal out of scope issue with `use_raf_fn`
## [0.10.10] - 2024-05-10

View file

@ -89,7 +89,7 @@ pub fn use_raf_fn_with_options(
let previous_frame_timestamp = Cell::new(0.0_f64);
move |timestamp: f64| {
if !is_active.get_untracked() {
if !is_active.try_get_untracked().unwrap_or_default() {
return;
}