add must use to several hooks

This commit is contained in:
Evan Almloff committed 2023-10-14 12:08:54 -05:00
1 parent 04f83e1e92
commit 3bf6d2d7cf
21 files changed
+25

No files matched your search

+1
View File
@@ -33,6 +33,7 @@ type EvalCreator = Rc<dyn Fn(&str) -> Result<UseEval, EvalError>>;
/// parts is practically asking for a hacker to find an XSS vulnerability in
/// it. **This applies especially to web targets, where the JavaScript context
/// has access to most, if not all of your application data.**
#[must_use]
pub fn use_eval(cx: &ScopeState) -> &EvalCreator {
&*cx.use_hook(|| {
let eval_provider = cx