fix: terminal, restore, cross users (#12335)

Signed-off-by: fufesou <linlong1266@gmail.com>
This commit is contained in:
fufesou
2025-07-18 16:25:53 +08:00
committed by GitHub
parent bdd3bb946e
commit e91f4fc104
2 changed files with 12 additions and 5 deletions

View File

@@ -2551,7 +2551,7 @@ impl LoginConfigHandler {
}),
ConnType::TERMINAL => {
let mut terminal = Terminal::new();
terminal.service_id = self.get_option("terminal-service-id");
terminal.service_id = self.get_option(self.get_key_terminal_service_id());
lr.set_terminal(terminal);
}
_ => {}
@@ -2602,6 +2602,14 @@ impl LoginConfigHandler {
pub fn get_id(&self) -> &str {
&self.id
}
pub fn get_key_terminal_service_id(&self) -> &'static str {
if self.is_terminal_admin {
"terminal-admin-service-id"
} else {
"terminal-service-id"
}
}
}
/// Media data.