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.
mut
1 parent b259267 commit 91713a4Copy full SHA for 91713a4
src/lib.rs
@@ -121,10 +121,10 @@ impl Url {
121
/// ```
122
/// use ada_url::Url;
123
///
124
- /// let mut url = Url::parse("blob:https://example.com/foo", None).expect("Invalid URL");
+ /// let url = Url::parse("blob:https://example.com/foo", None).expect("Invalid URL");
125
/// assert_eq!(url.origin(), "https://example.com");
126
127
- pub fn origin(&mut self) -> &str {
+ pub fn origin(&self) -> &str {
128
unsafe {
129
let out = ffi::ada_get_origin(self.url);
130
let slice = std::slice::from_raw_parts(out.data.cast(), out.length);
0 commit comments