Skip to content

Commit

Permalink
fix cargo clippy
Browse files Browse the repository at this point in the history
add actions display show version
  • Loading branch information
a-wing committed May 20, 2024
1 parent 33418cf commit 81a0caa
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 3 deletions.
5 changes: 5 additions & 0 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,11 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Show version information
run: |
cargo --version
cargo clippy --version
- name: Cargo clippy
run: cargo clippy --all-targets --all-features --workspace -- -D warnings

2 changes: 1 addition & 1 deletion gateway/src/tick.rs
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ pub async fn node_sync_info(node: Node, pool: &Pool<MySql>) -> Result<()> {
.into_iter()
.map(|stream_info| {
let mut stream = Stream::from(stream_info);
stream.addr = node.addr.clone();
stream.addr.clone_from(&node.addr);
(stream.stream.clone(), stream.clone())
})
.collect();
Expand Down
4 changes: 2 additions & 2 deletions src/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -204,12 +204,12 @@ impl IceServer {
if self.username.is_empty() || self.credential.is_empty() {
return Err(Error::ErrNoTurnCredentials);
}
url.username = self.username.clone();
url.username.clone_from(&self.username);

match self.credential_type.as_str().into() {
RTCIceCredentialType::Password => {
// https://www.w3.org/TR/webrtc/#set-the-configuration (step #11.3.3)
url.password = self.credential.clone();
url.password.clone_from(&self.credential);
}
RTCIceCredentialType::Oauth => {
// https://www.w3.org/TR/webrtc/#set-the-configuration (step #11.3.4)
Expand Down

0 comments on commit 81a0caa

Please sign in to comment.