(
socket: SocketRef,
socketioxide::extract::State(plugin): socketioxide::extract::State<Plugin<PluginState>>,
)
| 417 | } |
| 418 | |
| 419 | pub async fn auth_socket_io_middleware( |
| 420 | socket: SocketRef, |
| 421 | socketioxide::extract::State(plugin): socketioxide::extract::State<Plugin<PluginState>>, |
| 422 | ) -> Result<(), AppError> { |
| 423 | let rune = socket |
| 424 | .req_parts() |
| 425 | .headers |
| 426 | .get("rune") |
| 427 | .and_then(|v| v.to_str().ok()) |
| 428 | .map(String::from); |
| 429 | |
| 430 | let checkrune_params = CheckRuneParams { |
| 431 | nodeid: None, |
| 432 | method: Some("listclnrest-notifications".to_owned()), |
| 433 | params: None, |
| 434 | }; |
| 435 | verify_rune(&plugin, rune, &checkrune_params).await |
| 436 | } |
nothing calls this directly
no test coverage detected