We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
TypeError
string
1 parent 1bd5f69 commit 308e646Copy full SHA for 308e646
src/lib.rs
@@ -1,3 +1,4 @@
1
+use js_sys::TypeError;
2
use lol_html::html_content::ContentType as NativeContentType;
3
use std::cell::Cell;
4
use std::convert::Into;
@@ -57,7 +58,9 @@ impl<R> NativeRefWrap<R> {
57
58
59
fn assert_not_poisoned(&self) -> JsResult<()> {
60
if self.poisoned.get() {
- Err("The object has been freed and can't be used anymore.".into())
61
+ Err(TypeError::new(
62
+ "This content token is no longer valid. Content tokens are only valid during the execution of the relevant content handler.",
63
+ ).into())
64
} else {
65
Ok(())
66
}
0 commit comments