chore: Fix several style lints (#17488)

It's not comprehensive enough to start linting on `style` group, but
hey, it's a start.

Release Notes:

- N/A
This commit is contained in:
Piotr Osiewicz 2024-09-06 11:58:39 +02:00 committed by GitHub
parent 93249fc82b
commit e6c1c51b37
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
361 changed files with 3530 additions and 3587 deletions

View file

@ -11,12 +11,12 @@ pub struct Session {
old_window_ids: Option<Vec<WindowId>>,
}
const SESSION_ID_KEY: &'static str = "session_id";
const SESSION_WINDOW_STACK_KEY: &'static str = "session_window_stack";
const SESSION_ID_KEY: &str = "session_id";
const SESSION_WINDOW_STACK_KEY: &str = "session_window_stack";
impl Session {
pub async fn new() -> Self {
let old_session_id = KEY_VALUE_STORE.read_kvp(&SESSION_ID_KEY).ok().flatten();
let old_session_id = KEY_VALUE_STORE.read_kvp(SESSION_ID_KEY).ok().flatten();
let session_id = Uuid::new_v4().to_string();
@ -26,7 +26,7 @@ impl Session {
.log_err();
let old_window_ids = KEY_VALUE_STORE
.read_kvp(&SESSION_WINDOW_STACK_KEY)
.read_kvp(SESSION_WINDOW_STACK_KEY)
.ok()
.flatten()
.and_then(|json| serde_json::from_str::<Vec<u64>>(&json).ok())