Skip to content

Commit b3cec50

Browse files
committed
lint
1 parent c74db78 commit b3cec50

File tree

2 files changed

+4
-6
lines changed

2 files changed

+4
-6
lines changed

examples/api/src-tauri/src/lib.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -114,8 +114,8 @@ pub fn run() {
114114
headers.push(
115115
tiny_http::Header::from_bytes(
116116
&b"Set-Cookie"[..],
117-
&format!("session-token=test-value; Secure; Path=/; Expires={expires_str}")
118-
.as_bytes()[..],
117+
format!("session-token=test-value; Secure; Path=/; Expires={expires_str}")
118+
.as_bytes(),
119119
)
120120
.unwrap(),
121121
);

plugins/http/src/lib.rs

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -43,15 +43,13 @@ pub fn init<R: Runtime>() -> TauriPlugin<R> {
4343
.open(&path)?;
4444

4545
let reader = BufReader::new(file);
46-
let store = CookieStoreMutex::load(path.clone(), reader).unwrap_or_else(|_e| {
46+
CookieStoreMutex::load(path.clone(), reader).unwrap_or_else(|_e| {
4747
#[cfg(feature = "tracing")]
4848
tracing::warn!(
4949
"failed to load cookie store: {_e}, falling back to empty store"
5050
);
5151
CookieStoreMutex::new(path, Default::default())
52-
});
53-
54-
store
52+
})
5553
};
5654

5755
let state = Http {

0 commit comments

Comments
 (0)